We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug
SQL identifiers should be case-insensitive unless in double quotes. This is not currently the case for subquery aliases.
To Reproduce
Add this test to datafusion/core/tests/sql/projection.rs
datafusion/core/tests/sql/projection.rs
#[tokio::test] async fn subquery_alias_case_insensitive() -> Result<()> { let partition_count = 1; let results = partitioned_csv::execute("SELECT V1.c1, v1.C2 FROM (SELECT test.C1, TEST.c2 FROM test) V1 ORDER BY v1.c1, V1.C2 LIMIT 1", partition_count).await?; let expected = vec![ "+----+----+", "| c1 | c2 |", "+----+----+", "| 3 | 1 |", "+----+----+", ]; assert_batches_sorted_eq!(expected, &results); Ok(()) }
Fails with:
Error: Plan("No field named 'v1.c1'. Valid fields are 'V1.c1', 'V1.c2'.")
Expected behavior SQL planner should normalize the identifier.
Additional context None
The text was updated successfully, but these errors were encountered:
andygrove
Successfully merging a pull request may close this issue.
Describe the bug
SQL identifiers should be case-insensitive unless in double quotes. This is not currently the case for subquery aliases.
To Reproduce
Add this test to
datafusion/core/tests/sql/projection.rs
Fails with:
Expected behavior
SQL planner should normalize the identifier.
Additional context
None
The text was updated successfully, but these errors were encountered: