"SUM(SELECT\n X\nFROM PUBLIC.\"\" BB\n /* SELECT\n SUM(1) AS X,\n A\n FROM PUBLIC.B\n /++ PUBLIC.B.tableScan ++/\n /++ WHERE A IS ?1\n ++/\n /++ scanCount: 4 ++/\n INNER JOIN PUBLIC.C\n /++ PUBLIC.C.tableScan ++/\n ON 1=1\n WHERE (A IS ?1)\n AND (B.VAL = C.B)\n GROUP BY A: A IS A.VAL\n */\n /* scanCount: 1 */\nWHERE BB.A IS A.VAL)"};
"SUM(SELECT\n"+
intexpectedNumberOfRows=3;
" X\n"+
"FROM PUBLIC.\"\" BB\n"+
" /* SELECT\n"+
" SUM(1) AS X,\n"+
" A\n"+
" FROM PUBLIC.B\n"+
" /++ PUBLIC.B.tableScan ++/\n"+
" /++ WHERE A IS ?1\n"+
" ++/\n"+
" /++ scanCount: 4 ++/\n"+
" INNER JOIN PUBLIC.C\n"+
" /++ PUBLIC.C.tableScan ++/\n"+
" ON 1=1\n"+
" WHERE (A IS ?1)\n"+
" AND (B.VAL = C.B)\n"+
" GROUP BY A: A IS A.VAL\n"+
" */\n"+
" /* scanCount: 1 */\n"+
"WHERE BB.A IS A.VAL)"};
StringSETUP_SQL=
StringSETUP_SQL=
"DROP TABLE IF EXISTS A; "
"DROP TABLE IF EXISTS A; "
+"DROP TABLE IF EXISTS B; "
+"DROP TABLE IF EXISTS B; "
+"DROP TABLE IF EXISTS C; "
+"DROP TABLE IF EXISTS C; "
+"CREATE TABLE A(VAL VARCHAR(255)); "
+"CREATE TABLE A(VAL VARCHAR(255)); "
+"CREATE TABLE B(A VARCHAR(255), VAL VARCHAR(255)); "
+"CREATE TABLE B(A VARCHAR(255), VAL VARCHAR(255)); "
+"CREATE TABLE C(B VARCHAR(255), VAL VARCHAR(255)); "
+"CREATE TABLE C(B VARCHAR(255), VAL VARCHAR(255)); "
+" "
+" "
+"INSERT INTO A VALUES('fruit'); "
+"INSERT INTO A VALUES('fruit'); "
+"INSERT INTO B VALUES('fruit','apple'); "
+"INSERT INTO B VALUES('fruit','apple'); "
+"INSERT INTO B VALUES('fruit','banana'); "
+"INSERT INTO B VALUES('fruit','banana'); "
+"INSERT INTO C VALUES('apple', 'golden delicious');"
+"INSERT INTO C VALUES('apple', 'golden delicious');"
+"INSERT INTO C VALUES('apple', 'granny smith'); "
+"INSERT INTO C VALUES('apple', 'granny smith'); "