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
Snowflake is case-insensitive if you use identifier without double quotes, But its case sensitive with double quotes. (https://docs.snowflake.com/en/sql-reference/identifiers-syntax.html)
But data-knex-snowflake-dialect always emits query with columns that are in upper-case.
For example:
const connection = knex({ client: SnowflakeDialect, }) const builder = connection('TABLE1') .withSchema('SCHEMA1') .select({ 'Id': 'id' })
Expected: select "TABLE1"."id" as "Id" from "SCHEMA1"."TABLE1" Actual: select "TABLE1"."ID" as "ID" from "SCHEMA1"."TABLE1"
select "TABLE1"."id" as "Id" from "SCHEMA1"."TABLE1"
select "TABLE1"."ID" as "ID" from "SCHEMA1"."TABLE1"
Note: alias name and column name - both have to be case sensitive.
Workaround:
const builder = connection('TABLE1') .withSchema('SCHEMA1') .select([ knex.ref( knex.raw('id') ).as( knex.raw('Id') )])
With this, I am able to make column name and alias however i want
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Snowflake is case-insensitive if you use identifier without double quotes, But its case sensitive with double quotes.
(https://docs.snowflake.com/en/sql-reference/identifiers-syntax.html)
But data-knex-snowflake-dialect always emits query with columns that are in upper-case.
For example:
Expected:
select "TABLE1"."id" as "Id" from "SCHEMA1"."TABLE1"
Actual:
select "TABLE1"."ID" as "ID" from "SCHEMA1"."TABLE1"
Note: alias name and column name - both have to be case sensitive.
Workaround:
With this, I am able to make column name and alias however i want
The text was updated successfully, but these errors were encountered: