MuhammadTahaNaveed commented on PR #1262:
URL: https://github.com/apache/age/pull/1262#issuecomment-1750758008
@rafsun42 Shoudn't this work for filters applied using `WHERE` clause as
well? Currently its not....
```
explain_review=# SET age.enable_containment = off;
SET
explain_review=# SELECT * FROM cypher('test_enable_containmentt', $$ EXPLAIN
MATCH (x {name:'Bob'}) RETURN x $$) as (a agtype);
QUERY PLAN
----------------------------------------------------------------------------------------------------
Seq Scan on _ag_label_vertex x (cost=0.00..28.03 rows=6 width=32)
Filter: (agtype_access_operator(VARIADIC ARRAY[properties,
'"name"'::agtype]) = '"Bob"'::agtype)
(2 rows)
explain_review=# SELECT * FROM cypher('test_enable_containmentt', $$ EXPLAIN
MATCH (x) WHERE x.name='Bob' RETURN x $$) as (a agtype);
QUERY PLAN
----------------------------------------------------------------------------------------------------
Seq Scan on _ag_label_vertex x (cost=0.00..28.03 rows=6 width=32)
Filter: (agtype_access_operator(VARIADIC ARRAY[properties,
'"name"'::agtype]) = '"Bob"'::agtype)
```
```
explain_review=# SET age.enable_containment = on;
SET
explain_review=# SELECT * FROM cypher('test_enable_containmentt', $$ EXPLAIN
MATCH (x {name:'Bob'}) RETURN x $$) as (a agtype);
QUERY PLAN
--------------------------------------------------------------------
Seq Scan on _ag_label_vertex x (cost=0.00..25.00 rows=1 width=32)
Filter: (properties @> '{"name": "Bob"}'::agtype)
(2 rows)
explain_review=# SELECT * FROM cypher('test_enable_containmentt', $$ EXPLAIN
MATCH (x) WHERE x.name='Bob' RETURN x $$) as (a agtype);
QUERY PLAN
----------------------------------------------------------------------------------------------------
Seq Scan on _ag_label_vertex x (cost=0.00..28.03 rows=6 width=32)
Filter: (agtype_access_operator(VARIADIC ARRAY[properties,
'"name"'::agtype]) = '"Bob"'::agtype)
(2 rows)
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]