Peeyush Gupta created ASTERIXDB-3403:
----------------------------------------
Summary: Compilation error with valid query
Key: ASTERIXDB-3403
URL: https://issues.apache.org/jira/browse/ASTERIXDB-3403
Project: Apache AsterixDB
Issue Type: Bug
Components: COMP - Compiler
Reporter: Peeyush Gupta
The following query fails compilation
{noformat}
SELECT COUNT(id) AS matches
FROM collection1 AS d
WHERE d.`f1` = 'f1'
AND (ARRAY_SUM((
SELECT VALUE i.`cnt`
FROM d.`x1` AS i
WHERE i.`date` BETWEEN "01-01-2024" AND "02-02-2024"
AND i.`item` IN ['1234', '5678'] )) >= 1
OR ARRAY_SUM((
SELECT VALUE i.`cnt`
FROM d.`x2` AS i
WHERE i.`date` BETWEEN "01-01-2024" AND "02-02-2024"
AND i.`item` IN ['1234', '5678'] )) >= 1
OR (ANY e IN d.x3 SATISFIES e.item IN ['i1', 'i2', 'i3']
AND e.su.`x4` >= 1 END));{noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)