Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
Anonymous
Not applicable

Issue creating a snowflake data source using gateway

Im trying to create a new datasource usign Snowflake type into a gateway, When I run the model Im getting the next error 'ODBC ERROR 22000 Cannnot perform SELECT. This session does not have a current database Call USE DATABASE or use a qualified name' In the settings I didnt see database option to type it I see just 'Server' & Warehouse. So could someone help me with your inputs on this

2 REPLIES 2
v-henryk-mstf
Community Support
Community Support

Hi @Anonymous ,

 

It sounds like you are trying to connect to a Snowflake database using an ODBC connection and you are encountering an error when you try to run a SELECT statement. The error message indicates that you need to specify a database to use for the connection.

In Snowflake, a database is a logical container for a set of tables and other objects. When you create a connection to a Snowflake account, you need to specify the name of the database that you want to connect to.

To specify the database to use for the connection, you can use the "Database" option in the connection settings. This option is usually located in the same section as the "Server" and "Warehouse" options. You will need to enter the name of the database that you want to connect to in this field.

Alternatively, you can also specify the database to use in your SQL statements by using a qualified name. A qualified name consists of the name of the database, followed by a period (.) and the name of the object (e.g. "database_name.table_name").

 

For example, you could use a statement like this to select data from a table in a specific database:

SELECT * FROM database_name.table_name;


I hope this helps! Let me know if you have any more questions.


Best Regards,
Henry


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi v-henryk-mstf

My apologies but for any reason I dont have the database option when I try to create a new data source On-premises, I selected 'Snowflake' as Data source type, and I have Server and Warehouse options. Here you can find an image that I see. Do you know where database should be?

Melinda_0-1672321952100.png

 

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.