Add contains operator
authorPeter Geoghegan <[email protected]>
Thu, 6 Mar 2014 00:43:04 +0000 (16:43 -0800)
committerPeter Geoghegan <[email protected]>
Thu, 6 Mar 2014 00:43:04 +0000 (16:43 -0800)
src/include/catalog/pg_operator.h
src/include/catalog/pg_proc.h

index c522e0fdd685614c2e22cad82da0afa9040a2aec..3b290c97abe9e2a2f78db19706cdeeb2cce7c87a 100644 (file)
@@ -1793,7 +1793,9 @@ DATA(insert OID = 3244 (  "<="    PGNSP PGUID b f f 3802 3802 16 3245 3243 jsonb_le
 DESCR("less than or equal to");
 DATA(insert OID = 3245 (  ">=" PGNSP PGUID b f f 3802 3802 16 3244 3242 jsonb_ge scalargtsel scalargtjoinsel ));
 DESCR("greater than or equal to");
-
+/* No commutator? */
+DATA(insert OID = 3246 (  "@>"    PGNSP PGUID b f f 3802 3802 16 0 0 jsonb_contains contsel contjoinsel ));
+DESCR("contains");
 
 
 /*
index a07937636256dca99d5943fe853d31b7f49ff148..df7f343c98dea41a5d537f73883c26158547e6d7 100644 (file)
@@ -4554,6 +4554,8 @@ DATA(insert OID = 4044 (  jsonb_cmp          PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0
 DESCR("less-equal-greater");
 DATA(insert OID = 4045 (  jsonb_hash      PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0 23 "3802" _null_ _null_ _null_ _null_ jsonb_hash _null_ _null_ _null_ ));
 DESCR("hash");
+DATA(insert OID = 4046 (  jsonb_contains   PGNSP PGUID 12 1 0 0 0 f f f f t f i 2 0 16 "3802 3802" _null_ _null_ _null_ _null_ jsonb_contains _null_ _null_ _null_ ));
+DESCR("implementation of @> operator");
 DATA(insert OID =  3479 (  gjsonb_in       PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0 3801 "2275" _null_ _null_ _null_ _null_ gjsonb_in _null_ _null_ _null_ ));
 DESCR("GiST support");
 DATA(insert OID =  3480 (  gjsonb_out      PGNSP PGUID 12 1 0 0 0 f f f f t f i 1 0 2275 "3801" _null_ _null_ _null_ _null_ gjsonb_out _null_ _null_ _null_ ));