Skip to content

Partially revert to fix the case where schema config contains uppercase letters.#224

Merged
ueshin merged 3 commits into
databricks:mainfrom
ueshin:revert_schema
Nov 4, 2022
Merged

Partially revert to fix the case where schema config contains uppercase letters.#224
ueshin merged 3 commits into
databricks:mainfrom
ueshin:revert_schema

Conversation

@ueshin
Copy link
Copy Markdown
Contributor

@ueshin ueshin commented Nov 3, 2022

Description

Partially reverts #221 to fix the case where schema config contains uppercase letters.

Compilation Error in model test (models/test.sql)
  When searching for a relation, dbt found an approximate match. Instead of guessing
  which relation to use, dbt will move on. Please delete DBT_TEST.test, or rename it to be less ambiguous.
  Searched for: dbt_test.test
  Found: DBT_TEST.test

  > in macro load_cached_relation (macros/adapters/relation.sql)
  > called by macro load_relation (macros/adapters/relation.sql)
  > called by macro materialization_incremental_databricks (macros/materializations/incremental/incremental.sql)
  > called by model test (models/test.sql)

f"got {len(row)} values, expected 4"
)
_, name, _, information = row
_schema, name, _, information = row
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we comment here on why we need the schema returned from the row?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, left a comment.
Actually we might have a better way to handle this, but let me just revert to avoid the current regression.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good!

@ueshin
Copy link
Copy Markdown
Contributor Author

ueshin commented Nov 4, 2022

Thanks! merging.

@ueshin ueshin merged commit bc80ea3 into databricks:main Nov 4, 2022
@ueshin ueshin deleted the revert_schema branch November 4, 2022 23:33
ueshin added a commit that referenced this pull request Nov 4, 2022
…se letters. (#224)

### Description

Partially reverts #221 to fix the case where `schema` config contains uppercase letters.

```
Compilation Error in model test (models/test.sql)
  When searching for a relation, dbt found an approximate match. Instead of guessing
  which relation to use, dbt will move on. Please delete DBT_TEST.test, or rename it to be less ambiguous.
  Searched for: dbt_test.test
  Found: DBT_TEST.test

  > in macro load_cached_relation (macros/adapters/relation.sql)
  > called by macro load_relation (macros/adapters/relation.sql)
  > called by macro materialization_incremental_databricks (macros/materializations/incremental/incremental.sql)
  > called by model test (models/test.sql)
```
ueshin added a commit that referenced this pull request Nov 4, 2022
…se letters. (#224)

### Description

Partially reverts #221 to fix the case where `schema` config contains uppercase letters.

```
Compilation Error in model test (models/test.sql)
  When searching for a relation, dbt found an approximate match. Instead of guessing
  which relation to use, dbt will move on. Please delete DBT_TEST.test, or rename it to be less ambiguous.
  Searched for: dbt_test.test
  Found: DBT_TEST.test

  > in macro load_cached_relation (macros/adapters/relation.sql)
  > called by macro load_relation (macros/adapters/relation.sql)
  > called by macro materialization_incremental_databricks (macros/materializations/incremental/incremental.sql)
  > called by model test (models/test.sql)
```
ueshin added a commit that referenced this pull request Nov 4, 2022
…se letters. (#224)

### Description

Partially reverts #221 to fix the case where `schema` config contains uppercase letters.

```
Compilation Error in model test (models/test.sql)
  When searching for a relation, dbt found an approximate match. Instead of guessing
  which relation to use, dbt will move on. Please delete DBT_TEST.test, or rename it to be less ambiguous.
  Searched for: dbt_test.test
  Found: DBT_TEST.test

  > in macro load_cached_relation (macros/adapters/relation.sql)
  > called by macro load_relation (macros/adapters/relation.sql)
  > called by macro materialization_incremental_databricks (macros/materializations/incremental/incremental.sql)
  > called by model test (models/test.sql)
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants