Dmitry Lychagin created ASTERIXDB-2408:
------------------------------------------
Summary: Query runs into stack overflow
Key: ASTERIXDB-2408
URL: https://issues.apache.org/jira/browse/ASTERIXDB-2408
Project: Apache AsterixDB
Issue Type: Bug
Components: COMP - Compiler
Reporter: Dmitry Lychagin
Assignee: Dmitry Lychagin
The following query runs into stack overflow:
drop dataverse test if exists;
create dataverse test;
use test;
create type testType as open
{ id: int32 };
create dataset customers(testType) primary key id;
create dataset orders(testType) primary key id;
SELECT c.name, (
SELECT VALUE o.id
FROM orders o
WHERE o.customer_id = c.id
) AS orders
FROM customers c
ORDER BY array_count(orders)
;
Stack trace:
java.lang.StackOverflowError
at java.util.HashMap.hash(HashMap.java:339)
at java.util.LinkedHashMap.get(LinkedHashMap.java:440)
at org.apache.asterix.lang.common.context.Scope.findSymbol(Scope.java:63)
at org.apache.asterix.lang.common.context.Scope.findSymbol(Scope.java:65)
at org.apache.asterix.lang.common.context.Scope.findSymbol(Scope.java:65)
at org.apache.asterix.lang.common.context.Scope.findSymbol(Scope.java:65)
at org.apache.asterix.lang.common.context.Scope.findSymbol(Scope.java:65)
at org.apache.asterix.lang.common.context.Scope.findSymbol(Scope.java:65)
...
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)