Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extend agtype containment operators (@>, <@) #1285

Merged
merged 1 commit into from
Oct 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion age--1.4.0.sql
Original file line number Diff line number Diff line change
Expand Up @@ -3170,7 +3170,8 @@ PARALLEL SAFE;

CREATE OPERATOR CLASS ag_catalog.gin_agtype_ops
DEFAULT FOR TYPE agtype USING gin AS
OPERATOR 7 @>,
OPERATOR 7 @>(agtype, agtype),
OPERATOR 8 <@(agtype, agtype),
OPERATOR 9 ?(agtype, agtype),
OPERATOR 10 ?|(agtype, agtype),
OPERATOR 11 ?&(agtype, agtype),
Expand Down
24 changes: 0 additions & 24 deletions regress/expected/agtype.out
Original file line number Diff line number Diff line change
Expand Up @@ -3205,30 +3205,6 @@ SELECT age_end_id(agtype_in('null'));

(1 row)

SELECT agtype_contains('{"id": 1}','{"id": 1}');
agtype_contains
-----------------
t
(1 row)

SELECT agtype_contains('{"id": 1}','{"id": 2}');
agtype_contains
-----------------
f
(1 row)

SELECT '{"id": 1}'::agtype @> '{"id": 1}';
?column?
----------
t
(1 row)

SELECT '{"id": 1}'::agtype @> '{"id": 2}';
?column?
----------
f
(1 row)

--
-- Test STARTS WITH, ENDS WITH, and CONTAINS
--
Expand Down
Loading