Skip to content
LearningPathX
Learning PathsFree TestsExam InfoHow it worksNews
Sign inChoose a certification
  1. Home/
  2. Certifications/
  3. COF-C03/
  4. COF-C03 Learning Path/
  5. Study FAQs/
  6. Why can I sign in to Snowflake but still get an access denied error when I query data?

Study FAQ

Why can I sign in to Snowflake but still get an access denied error when I query data?

Exam · COF-C03Knowledge domain · Account Management and Data GovernanceUpdated Nov 25, 2026
Also asked as 2
  • How do I find the missing role or grant when a Snowflake query fails after login?
  • What should I check if an administrator can run a Snowflake query but my user cannot?

Answer

Once sign-in succeeds, check the failing session's account, active roles, warehouse and object path. For a warehouse-backed SELECT, the active and inherited roles generally need warehouse USAGE, access to the database and schema, and SELECT on the named table or view.

  1. In the failing session, check CURRENT_ROLE(), CURRENT_SECONDARY_ROLES(), CURRENT_WAREHOUSE(), CURRENT_DATABASE() and CURRENT_SCHEMA(). Compare the account and a fully qualified object name with the working session. A user's default role sets initial context and must already have been granted to that user. A client connection can choose a different role.
  2. With a diagnostic role that has sufficient visibility, use SHOW GRANTS TO USER and SHOW GRANTS TO ROLE and follow inherited account and database roles to the required grants. Check whether the administrator is succeeding through an ownership path that the functional role lacks.
  3. Correct the missing link, then repeat the original query with the intended user, role and warehouse. If you isolate the test with USE SECONDARY ROLES NONE, restore the application's normal role configuration before final verification.

CURRENT_ROLE() reports the primary role. Most statements can use privileges from active primary and secondary roles and their hierarchies. Authorization to create an object uses the primary role and its hierarchy, and the active primary role owns the new object.

Access control overview · Access control privileges · SHOW GRANTS · USE SECONDARY ROLES

Full explanation

Managing Snowflake Accounts, Organizations, Roles, and Access

Study guide · COF-C03

Read the full explanation →
← Back to COF-C03 FAQsView learning path →

Related questions

Which Snowflake history should I use to investigate an account activity event? →When should I use a Snowflake resource monitor or a budget? →How should people and automated services authenticate to Snowflake? →How do Snowflake network rules and policy precedence affect a connection? →How should Snowflake administrators divide role management, object ownership, and grants? →What should I check before using a Snowflake clone as a test environment? →
LearningPathX

A focused path to certification, one clear step at a time.

© 2026 LearningPathX. All rights reserved.

Product

CertificationsLearning PathsFree TestsHow it worksNews

Company

SubscriptionHelp centerContact usPrivacyTerms

Follow us

Your privacy choices

We use analytics cookies to understand how LearningPathX is used and improve your learning experience. Analytics will only start after you accept.