pub fn array_contained<'a, L, R>(
left: L,
right: R,
) -> SQLExpr<'a, PostgresValue<'a>, Bool, NonNull, Scalar>Expand description
PostgreSQL <@ operator - array is contained by.
Returns true if the left array is contained by the right array (i.e., all elements of left are in right).
ยงExample
let tags = SQL::<PostgresValue>::raw("tags");
let condition = array_contained(tags, "rust");
assert!(condition.to_sql().sql().contains("<@"));
// Generates: tags <@ $1