-
Notifications
You must be signed in to change notification settings - Fork 427
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
snowflake_databases does not return any databases #1383
Comments
This sounds like a permission issue. Have you confirmed the role you're using has access to list the db? |
yes, it's the same role that created everything including databases so I
would expect it to return some in a list. Hmm, but let me turn logging on
and double check it's empty.
…On Mon, 19 Dec 2022 at 12:58, Benny Lu ***@***.***> wrote:
This sounds like a permission issue. Have you confirmed the role you're
using has access to list the db?
—
Reply to this email directly, view it on GitHub
<#1383 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIK2ZH73HZNAKZBCEWKVK63WN6QJNANCNFSM6AAAAAASIGB6NM>
.
You are receiving this because you authored the thread.Message ID:
***@***.***
.com>
|
I am also facing the same issue, I can confirm the role is correct and can see SHOW DATABASES LIKE "XXX" being executed under the correct role and return data. Other data sources like snowflake_role are working fine. I'm not sure if this of relevance, but |
I'm unable to reproduce this bug. I would confirm that the role is able to list the database One thing to note is the provider puts double-quotes to qualify everything so it is case sensitive. For example if you created your database as "test" you need to pass "test" and not "TEST" to the data source |
The more general case is that no databases are returned from the snowflake_databases data provider
I can see the query in Snowflake and it returns the correct list of databases. It doesn't show in the terraform state. I don't know what the difference could be |
@jifeous @jag-super @bennylu2 did you ever figure out what the issue here was? I'm running into the same thing |
@brettwatkins-Built No I didn't, you may want to try the latest provider version, as I was using a very old one and there have been changes. |
no, didn't figure it out and just did something else in the end
…On Wed, 22 Nov 2023 at 23:43, jag-super ***@***.***> wrote:
@brettwatkins-Built <https://github.com/brettwatkins-Built> No I didn't,
you may want to try the latest provider version, as I was using a very old
one and there have been changes.
—
Reply to this email directly, view it on GitHub
<#1383 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIK2ZH3EG3T3RFQPUNPXC2TYFXJLXAVCNFSM6AAAAAASIGB6NOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMRSGUZDGMBTHA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***
.com>
|
Provider Version
Terraform v1.3.2
on windows_amd64
Describe the bug
Using the snowflake_databases and snowflake_database data provider returns only nulls and does not return the expected db. If I check the snowflake query history I can see that it has run the correct sql "SHOW DATABASES LIKE "MYDB"".
Expected behavior
Returns the db so that I can use it to create a schema
Code samples and commands
data "snowflake_database" "domain" {
name = "MYDB"
}
output "snowflake_database" {
description = "Where is my db?"
value = data.snowflake_database.domain
}
The text was updated successfully, but these errors were encountered: