the following is returned:
{"timestamp":"2021-01-08T19:32:04.644+0000","status":500,"error":"Internal Server Error","message":"500 Server Error","path":"/api/query"}
log of the typhonQL server
19:18:18.932 [qtp402405659-13] ERROR engineering.swat.typhonql.server.QLRestServer - Failed to handle response
org.rascalmpl.interpreter.control_exceptions.Throw: |lib://typhonql/src/lang/typhonql/RunUsingCompiler.rsc|:249,69: "Error parsing:\nfrom EXTENT e select e where e.bounding_box in #polygon(130.7955 -19.742, 130.7955 1.9883, 165.2834 1.9883, 165.2834 -19.742, 130.7955 -19.742)\nposition: \<1,56> -- \<1,57>"
at org.rascalmpl.interpreter.control_exceptions.ControlException.reallyFillInStackTrace(ControlException.java:42) ~[rascal-0.18.2.jar:?]
if removing one set of brakets"(" ")", the error is in the "#" character. if removing the "#" character, the error is in the first coma in the points
Describe the bug
When executing this QL query via the HTTP API
{ "query": "from EXTENT e select e where e.bounding_box in #polygon((130.7955 -19.742, 130.7955 1.9883, 165.2834 1.9883, 165.2834 -19.742, 130.7955 -19.742))" }
we gen an error related to the query parsing what is the correct syntax for the spatial select using a polygon item?
Query
Model
Expected behavior
list of results
REST API
the following is returned: {"timestamp":"2021-01-08T19:32:04.644+0000","status":500,"error":"Internal Server Error","message":"500 Server Error","path":"/api/query"}
log of the typhonQL server
19:18:18.932 [qtp402405659-13] ERROR engineering.swat.typhonql.server.QLRestServer - Failed to handle response org.rascalmpl.interpreter.control_exceptions.Throw: |lib://typhonql/src/lang/typhonql/RunUsingCompiler.rsc|:249,69: "Error parsing:\nfrom EXTENT e select e where e.bounding_box in #polygon(130.7955 -19.742, 130.7955 1.9883, 165.2834 1.9883, 165.2834 -19.742, 130.7955 -19.742)\nposition: \<1,56> -- \<1,57>" at org.rascalmpl.interpreter.control_exceptions.ControlException.reallyFillInStackTrace(ControlException.java:42) ~[rascal-0.18.2.jar:?]
if removing one set of brakets"(" ")", the error is in the "#" character. if removing the "#" character, the error is in the first coma in the points
130.7955 -19.742, <-----