Open lordpretzel opened 3 years ago
GProM is not adding parentheses were needed to encode the evaluation order of set operations
For example (R - S) u (T - U) is serialized as
(R - S) u (T - U)
SELECT * FROM R EXCEPT SELECT * FROM S UNION ALL SELECT * FROM T EXCEPT SELECT * FROM U
which is the same as
((((SELECT * FROM R) EXCEPT SELECT * FROM S) UNION ALL SELECT * FROM T) EXCEPT SELECT * FROM U)
but the correct translation is:
((SELECT * FROM R EXCEPT SELECT * FROM S) UNION ALL (SELECT * FROM T EXCEPT SELECT * FROM U))
Commit ceec54bbb0e438e4fb0ad95f726294785252e6a1 resolved this bug for postgres. Check for other backends (SQLite chokes on parenthesis for set operations, will need a workaround there potentially.
GProM is not adding parentheses were needed to encode the evaluation order of set operations
For example
(R - S) u (T - U)
is serialized aswhich is the same as
but the correct translation is: