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

Fix the case-sensitive comparison on the seed name #436

Merged
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
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
- Fix get_columns_in_relation function to stop returning additional partition columns
- Fix null values handling in seeds
- Fix exceptions import for FailedToConnectError and ExecutableError

- Fix the case-sensitive comparison on the seed name

## v1.8.1
- Fix typo in README.md
- Fix unit test failure caused by moto 5 upgrade
Expand Down
2 changes: 1 addition & 1 deletion dbt/adapters/glue/impl.py
Original file line number Diff line number Diff line change
Expand Up @@ -539,7 +539,7 @@ def create_csv_table(self, model, agate_table):
csv = {json.loads(f.getvalue())}
df = spark.createDataFrame(csv)
table_name = '{model["schema"]}.{model["name"]}'
if (spark.sql("show tables in {model["schema"]}").where("tableName == '{model["name"]}'").count() > 0):
if (spark.sql("show tables in {model["schema"]}").where("tableName == lower('{model["name"]}')").count() > 0):
df.write\
.mode("{session.credentials.seed_mode}")\
.format("{session.credentials.seed_format}")\
Expand Down
Loading