You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What should happen: When my connection string contains something like DB="Development DB" (i.e. a database name with a spacve in it and surrounding double-quotes), a login request URL is supposed to formed that matches this: ...&databaseName="Development+DB"&...
What happens instead: This used to work up until commit 6df38a7 (17 Oct 2022, "fix 00402816 escape characters issue. (#531)"). That commit changed the parsing of the connection string by now using the DbConnectionStringBuilder. I am sure this was well-intended but it will swallow the surrounding double-quotes. The resulting login request URL is now: ...&databaseName=Development+DB&... (no double-quotes). Snowflake responds to that by saying "Error: The requested database does not exist or not authorized. SqlState: 08006, VendorCode: 390201"
The same problem exists for all tokens in the connection string. DB is just one example. You can also try with the warehouse, the role, ....
Hi @andrehartmann1968 , thanks for reporting this. I am able to reproduce the behavior and I can see this was introduced in version 2.0.18. Looks like a bug, but we'll confirm.
You may have fixed this for the database, but other tokens like the role and the warehouse also support spaces in their names. Even with the current version 3.0.0 this does not work. I still cannot upgrade the usage of the package beyond 2.0.17 because of this phenomenon. Could you please re-open this and fix it once and for good?
Issue description
What should happen: When my connection string contains something like DB="Development DB" (i.e. a database name with a spacve in it and surrounding double-quotes), a login request URL is supposed to formed that matches this: ...&databaseName="Development+DB"&...
What happens instead: This used to work up until commit 6df38a7 (17 Oct 2022, "fix 00402816 escape characters issue. (#531)"). That commit changed the parsing of the connection string by now using the DbConnectionStringBuilder. I am sure this was well-intended but it will swallow the surrounding double-quotes. The resulting login request URL is now: ...&databaseName=Development+DB&... (no double-quotes). Snowflake responds to that by saying "Error: The requested database does not exist or not authorized. SqlState: 08006, VendorCode: 390201"
The same problem exists for all tokens in the connection string. DB is just one example. You can also try with the warehouse, the role, ....
Example code
Configuration
Dotnet framework and version: .NET 6
The text was updated successfully, but these errors were encountered: