Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
Description
The UT in RelToSqlConverterTest:
@Test void testScalarSubqueryInSelectList() {
final String sql2 = "" +
"select\n" +
" (SELECT\n" +
" COUNT(*)\n" +
" FROM\n" +
" \"employee\"" +
" WHERE\n" +
" v.\"product_id\" >= 2), 3\n" +
"from \"product\" as v";
final String expected = "SELECT (((SELECT COUNT(*)\nFROM \"foodmart\".\"employee\"\nWHERE \"product\".\"product_id\" >= 2))), 3\n" +
"FROM \"foodmart\".\"product\"";
sql(sql2).ok(expected);
}
(((SELECT COUNT(*)\nFROM \"foodmart\".\"employee\"\nWHERE \"product\".\"product_id\" >= 2)))
should be:
(SELECT COUNT(*)\nFROM \"foodmart\".\"employee\"\nWHERE \"product\".\"product_id\" >= 2)
The result with redundant parentheses is correct but not sufficiently standardized.
Attachments
Issue Links
- links to