Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes undefined variable behavior tests #124

Merged
merged 1 commit into from
Sep 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 14 additions & 18 deletions partiql-tests-data/eval/query/group-by/group-by.ion
Original file line number Diff line number Diff line change
Expand Up @@ -982,9 +982,8 @@
result:EvaluationFail
},
{
result:EvaluationSuccess,
result:EvaluationFail,
evalMode:EvalModeCoerce,
output:$bag::[]
}
]
},
Expand All @@ -997,9 +996,8 @@
result:EvaluationFail
},
{
result:EvaluationSuccess,
result:EvaluationFail,
evalMode:EvalModeCoerce,
output:$bag::[]
}
]
},
Expand All @@ -1012,9 +1010,8 @@
result:EvaluationFail
},
{
result:EvaluationSuccess,
result:EvaluationFail,
evalMode:EvalModeCoerce,
output:$bag::[]
}
]
},
Expand All @@ -1027,9 +1024,8 @@
result:EvaluationFail
},
{
result:EvaluationSuccess,
result:EvaluationFail,
evalMode:EvalModeCoerce,
output:$bag::[]
}
]
}
Expand Down Expand Up @@ -7530,8 +7526,8 @@
}
},
{
name:"GROUP BY with JOIN : SELECT supplierName, COUNT(*) as the_count FROM suppliers AS s INNER JOIN products AS p ON s.supplierId = p.supplierId GROUP BY supplierName",
statement:"SELECT supplierName, COUNT(*) as the_count FROM suppliers AS s INNER JOIN products AS p ON s.supplierId = p.supplierId GROUP BY supplierName",
name:"GROUP BY with JOIN : SELECT supplierName, COUNT(*) as the_count FROM suppliers AS s INNER JOIN products AS p ON s.supplierId = p.supplierId GROUP BY s.supplierName",
statement:"SELECT supplierName, COUNT(*) as the_count FROM suppliers AS s INNER JOIN products AS p ON s.supplierId = p.supplierId GROUP BY s.supplierName",
assert:{
result:EvaluationSuccess,
evalMode:[
Expand Down Expand Up @@ -8166,8 +8162,8 @@
}
},
{
name:"SELECT col1, g FROM simple_1_col_1_group, join_me GROUP BY col1 GROUP AS g",
statement:"SELECT col1, g FROM simple_1_col_1_group, join_me GROUP BY col1 GROUP AS g",
name:"SELECT col1, g FROM simple_1_col_1_group, join_me GROUP BY simple_1_col_1_group.col1 GROUP AS g",
statement:"SELECT col1, g FROM simple_1_col_1_group, join_me GROUP BY simple_1_col_1_group.col1 GROUP AS g",
assert:{
result:EvaluationSuccess,
evalMode:[
Expand Down Expand Up @@ -8216,8 +8212,8 @@
}
},
{
name:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, join_me GROUP BY col1 GROUP AS g",
statement:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, join_me GROUP BY col1 GROUP AS g",
name:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, join_me GROUP BY simple_1_col_1_group.col1 GROUP AS g",
statement:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, join_me GROUP BY simple_1_col_1_group.col1 GROUP AS g",
assert:{
result:EvaluationSuccess,
evalMode:[
Expand Down Expand Up @@ -8266,8 +8262,8 @@
}
},
{
name:"SELECT col1, g FROM simple_1_col_1_group, different_types_per_row GROUP BY col1 GROUP AS g",
statement:"SELECT col1, g FROM simple_1_col_1_group, different_types_per_row GROUP BY col1 GROUP AS g",
name:"SELECT col1, g FROM simple_1_col_1_group, different_types_per_row GROUP BY simple_1_col_1_group.col1 GROUP AS g",
statement:"SELECT col1, g FROM simple_1_col_1_group, different_types_per_row GROUP BY simple_1_col_1_group.col1 GROUP AS g",
assert:{
result:EvaluationSuccess,
evalMode:[
Expand Down Expand Up @@ -8324,8 +8320,8 @@
}
},
{
name:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, different_types_per_row GROUP BY col1 GROUP AS g",
statement:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, different_types_per_row GROUP BY col1 GROUP AS g",
name:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, different_types_per_row GROUP BY simple_1_col_1_group.col1 GROUP AS g",
statement:"SELECT VALUE { 'col1': col1, 'g': g } FROM simple_1_col_1_group, different_types_per_row GROUP BY simple_1_col_1_group.col1 GROUP AS g",
assert:{
result:EvaluationSuccess,
evalMode:[
Expand Down
4 changes: 2 additions & 2 deletions partiql-tests-data/eval/query/select/select-mysql.ion
Original file line number Diff line number Diff line change
Expand Up @@ -11373,7 +11373,7 @@ select::[
},
{
name:"MYSQL_SELECT_20",
statement:"select fld3,period from t1,t2 where fld1 = 011401",
statement:"select t2.fld3,t1.period from t1,t2 where t2.fld1 = 011401",
assert:{
result:EvaluationSuccess,
evalMode:[
Expand All @@ -11390,7 +11390,7 @@ select::[
},
{
name:"MYSQL_SELECT_21",
statement:"select fld3,period from t2,t1 where companynr*10 = 37*10",
statement:"select t2.fld3,t1.period from t2,t1 where t2.companynr*10 = 37*10",
assert:{
result:EvaluationSuccess,
evalMode:[
Expand Down
9 changes: 3 additions & 6 deletions partiql-tests-data/eval/query/undefined-variable-behavior.ion
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ undefined_variable_behavior::[
assert:[
{
evalMode:EvalModeCoerce,
result:EvaluationSuccess,
output:$missing::null
result:EvaluationFail,
},
{
evalMode:EvalModeError,
Expand All @@ -24,8 +23,7 @@ undefined_variable_behavior::[
assert:[
{
evalMode:EvalModeCoerce,
result:EvaluationSuccess,
output:true
result:EvaluationFail,
},
{
evalMode:EvalModeError,
Expand All @@ -39,8 +37,7 @@ undefined_variable_behavior::[
assert:[
{
evalMode:EvalModeCoerce,
result:EvaluationSuccess,
output:true
result:EvaluationFail,
},
{
evalMode:EvalModeError,
Expand Down
Loading