CertSafari
    Snowflake SnowPro Core Certification (COF-C03)· Lessons

    Domain 1 · Lesson 2/19

    Snowflake CLI and the VS Code extension

    Use Snowflake Interfaces and tools

    11 min read
    5.17% of exam
    5 sources
    Published 5 Oct 2026
    Docs as of 4 Oct 2026

    What you will be able to do

    • Explain why the Snowflake CLI (snow) is preferred over the legacy SnowSQL client
    • Install the Snowflake CLI, verify it, and create a named connection
    • Install and sign in to the Snowflake extension for VS Code, and use it to run SQL
    • Recognise the VS Code extension's side effects on LAST_QUERY_ID() and how it reads SnowSQL configuration

    1.Snowflake CLI versus SnowSQL

    Snowflake has two command-line clients, and the exam expects you to know which one is current. The Snowflake CLI, whose command is snow, is the preferred client for new installs and new work. It is open source and built for developer workloads as well as SQL. SnowSQL is a legacy client for SQL queries, DDL, DML, and loading or unloading data. Snowflake supports SnowSQL 1.5.x through April 16, 2028, but all new features and enhancements go only into the Snowflake CLI.

    The CLI's scope goes well beyond running SQL. Developers use it to create, manage, update and view apps across Streamlit in Snowflake, the Native App Framework, Snowpark Container Services and Snowpark. It also handles user-defined functions, stored procedures and Git repositories. Snowflake describes these benefits of a command-line tool: speed, automation of building, testing, CI/CD and deployment, portability across operating systems, integration with version control, customisation, and remote access to servers that have no graphical interface. For Snowpark work, the CLI can read packages from requirements.txt and upload deployment artifacts to stages automatically.

    The documentation also carries a caution. Some snow commands execute code from your project directory, or fetch and execute content from remote URLs, so run them only on projects and sources you trust.

    Checkpoint 1 of 8· Check yourself

    A platform team is choosing a command-line client for a new pipeline that deploys Snowpark procedures and Streamlit apps from CI/CD. Which choice matches Snowflake's guidance?

    Sources12

    2.Installing snow and defining connections

    Snowflake recommends installing the CLI with a binary method such as a package manager. It is not currently available for AIX. On macOS, the community Homebrew formula installs it, though that formula might lag the latest release. Snowflake's own tap distributes a pre-built cask that is updated with every release. On Linux, the CLI comes as deb packages for Debian and Ubuntu and as rpm packages for RHEL, CentOS and Fedora. Whichever method you use, the CLI only works with a valid Snowflake account that holds the privileges each feature needs.

    Installing the Snowflake CLI with the community Homebrew formula on macOSbash
    brew install snowflake-cli

    Checkpoint 2 of 8· Fill the gap

    Which tool completes the Debian/Ubuntu install command for the Snowflake CLI package?

    sudo  ?  -i snowflake-cli-<version>.deb

    To verify the install, run snow --help. It lists the global options, such as --version, --info and --config-file, and the command groups. Each group maps to one area of Snowflake.

    Selected snow command groups and what each manages, from the snow --help output
    Command groupManages
    connectionConnections to Snowflake
    sqlExecutes a Snowflake query
    objectSnowflake objects like warehouses and stages
    stageStages
    gitGit repositories in Snowflake
    spcsSnowpark Container Services compute pools, services, image registries and repositories
    appA Snowflake Native App

    Checkpoint 3 of 8· Match them up

    Match each snow command group to what it manages

    Tap a term, then the definition that fits it.

    Next, define a connection. The snow connection commands create, manage and test connections. snow connection add prompts for a connection name, account and user, plus optional values such as role, warehouse, authenticator and private key file, then writes the result to the configuration file. Connections can be stored in config.toml or in a separate connections.toml in the same directory. If both files exist, the CLI reads connections only from connections.toml and ignores the ones in config.toml.

    If your account enforces MFA, the CLI asks for approval on every command. MFA caching cuts that to one authentication every four hours.

    Interactively creating a named connection and adding it to the configuration filebash
    snow connection add

    Checkpoint 4 of 8· Exam question

    A data engineer is writing a Snowpark Python script in Visual Studio Code and wants to browse the target database's schemas, preview up to 100 rows of a table, and inspect its DDL without leaving the editor. What should they use?

    Sources34

    3.The Snowflake extension for VS Code

    The Snowflake extension for Visual Studio Code lets you write and run Snowflake SQL inside the editor. It also adds debugging, syntax highlighting and autocomplete for SQL inside Snowpark Python code. You can install it from the Visual Studio Marketplace, or download a .vsix file and choose Install from VSIX. In the Marketplace, check for the Snowflake badge to make sure you have the official extension.

    Checkpoint 5 of 8· Put it in order

    Put the steps for installing the extension from the Marketplace in order

    1. 1.In VS Code, select Code > Settings > Extensions
    2. 2.Select Install
    3. 3.Enter Snowflake in the Search Extensions in Marketplace field and select the extension with the Snowflake badge

    Before you can run anything, you must sign in to a Snowflake account. The supported methods are account identifier plus username and password, federated authentication (SAML or SSO), key-pair authentication, and OAuth configured in your connections.toml file. To edit connections, open the extension's connections.toml with Snowflake: Edit Connections File. The extension can also load connections from an existing SnowSQL configuration file, set through the Snowsql Config Path setting. It reads only the connection values from that file and ignores every other SnowSQL setting.

    After you sign in, the sidebar shows your account, your default role, an Object Explorer with your databases, and Query History. A Native App pane manages Snowflake Native Apps. The session area shows the current role, database, schema and active warehouse.

    To run SQL, open or create a Snowflake SQL file. You can run every statement with Snowflake: Execute All Statements, or select specific statements and choose Execute; selected statements run top to bottom. Results open in the Snowsight results viewer, which displays up to 1 million rows. From there you can sort, hide or freeze columns, or save the results as CSV or gzip. Query History also lets you cancel queries that are still running.

    One side effect is worth remembering. To show results, the extension runs DESC RESULT on each query's ID in the background after every query, and that makes LAST_QUERY_ID() inaccurate.

    For Python developers, the extension shows an inline Snowflake: Debug option on a stored procedure written as a Python function whose first parameter is a Snowpark Session. You can set breakpoints. Within Python strings, the extension can detect SQL automatically and autocomplete table and column names.

    Checkpoint 6 of 8· Check yourself

    A developer runs a query in the VS Code extension, then calls LAST_QUERY_ID() to fetch its ID. The ID returned doesn't match their query. Why?

    Checkpoint 7 of 8· Check yourself

    A user points the VS Code extension's Snowsql Config Path at their existing SnowSQL configuration file. What does the extension take from it?

    Checkpoint 8 of 8· Exam question

    What is the primary distinction between the Snowflake CLI and SnowSQL?

    Sources5

    Exam traps

    Each one states something that sounds right. Open it to see what is actually true.

    1. 1.SnowSQL is Snowflake's current command-line tool, and the Snowflake CLI is an optional add-on.Why is that wrong?

      The Snowflake CLI (snow) is the preferred client. SnowSQL is legacy, supported in its 1.5.x versions through April 16, 2028, and gets no new features.

      Covered in Snowflake CLI versus SnowSQL

    2. 2.When connections are defined in both config.toml and connections.toml, the CLI merges the two sets.Why is that wrong?

      When both files exist, the CLI reads connections only from connections.toml and ignores those in config.toml.

      Covered in Installing snow and defining connections

    3. 3.Queries run from the VS Code extension leave LAST_QUERY_ID() pointing at your own last statement.Why is that wrong?

      To display results, the extension runs DESC RESULT in the background after every query, so LAST_QUERY_ID() returns the wrong ID.

      Covered in The Snowflake extension for VS Code

    Practise it for real

    Install the Snowflake CLI on macOS, confirm it works, and create a named connection to your account

    1. 1.Run brew install snowflake-cli

      Why: The community Homebrew formula is a supported binary install method on macOS

      You should see: Homebrew installs the snowflake-cli formula, which puts the snow command on your PATH

    2. 2.Open a new terminal and run snow --help

      Why: This confirms the install and shows which command groups are available

      You should see: Usage text listing options such as --version and --config-file, and command groups including connection, sql, stage and streamlit

    3. 3.Run snow connection add and answer the prompts for connection name, account, user and authenticator

      Why: Every later snow command needs a named connection to authenticate with

      You should see: The new connection is written to your configuration file. If you keep a connections.toml, it holds the connection and takes precedence over config.toml

    Stuck? Get a nudge

    If your account enforces MFA and every command asks for approval, look up MFA caching. It reduces authentication to once every four hours.

    Sources

    Every claim above is drawn from one of these pages, quoted as it was written on the date shown.

    1. 1.
      “Snowflake supports SnowSQL 1.5.x through April 16, 2028.”
      ↩︎ Snowflake CLI versus SnowSQL
      “With Snowflake CLI, developers can create, manage, update, and view apps running on Snowflake”
      ↩︎ Snowflake CLI versus SnowSQL
      “SnowSQL is a legacy command-line client.”
      ↩︎ Exam trap 1
      “Snowflake will only add new features and enhancements to Snowflake CLI.”
      ↩︎ Prediction
      “Snowflake CLI is the preferred command-line client for new installs and new work.”
      ↩︎ Checkpoint
    2. 2.
      “A CLI can automate tasks and workflows, such as building, testing, CI/CD, and deploying applications.”
      ↩︎ Snowflake CLI versus SnowSQL
      “Only run Snowflake CLI commands on projects, packages, and SQL sources you trust.”
      ↩︎ Snowflake CLI versus SnowSQL
    3. 3.
      “Snowflake recommends using binary installation methods, such as package managers, to install Snowflake CLI on your system.”
      ↩︎ Installing snow and defining connections
      “If your Snowflake account requires MFA (multi-factor authentication), Snowflake CLI requires approval for every command.”
      ↩︎ Installing snow and defining connections
      “Manages Snowflake objects like warehouses and stages”
      ↩︎ Checkpoint
    4. 4.
      “The snow connection commands let you create, manage, and test Snowflake connections.”
      ↩︎ Installing snow and defining connections
      “Place connections.toml in the same directory as config.toml.”
      ↩︎ Installing snow and defining connections
      “If both config.toml and connections.toml exist, Snowflake CLI reads connections from connections.toml and ignores those in config.toml.”
      ↩︎ Exam trap 2
    5. 5.
      “The Snowflake Visual Studio Code (VS Code) extension enables you to write and execute Snowflake SQL statements directly in VS Code.”
      ↩︎ The Snowflake extension for VS Code
      “Use OAuth authentication in your connections.toml configuration file.”
      ↩︎ The Snowflake extension for VS Code
      “This supports the display of up to 1 million rows.”
      ↩︎ The Snowflake extension for VS Code
      “To display Snowflake query results, the VS Code extension automatically runs DESC RESULT '<query_id>' in the background after every query.”
      ↩︎ Exam trap 3
      “In the Search Extensions in Marketplace field, enter Snowflake, and then select the Snowflake extension.”
      ↩︎ Checkpoint
      “This process makes LAST_QUERY_ID() inaccurate.”
      ↩︎ Checkpoint
      “Only connection configuration values are used. Other SnowSQL configuration values are ignored.”
      ↩︎ Checkpoint

    Ready to test yourself?

    Practise the 21 questions on this subdomain.

    Spotted a mistake, or was something unclear? Tell us.