Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
The Ultimate Guide to Snowpark

You're reading from   The Ultimate Guide to Snowpark Design and deploy Snowflake Snowpark with Python for efficient data workloads

Arrow left icon
Product type Paperback
Published in May 2024
Publisher Packt
ISBN-13 9781805123415
Length 254 pages
Edition 1st Edition
Languages
Arrow right icon
Authors (2):
Arrow left icon
Shankar Narayanan SGS Shankar Narayanan SGS
Author Profile Icon Shankar Narayanan SGS
Shankar Narayanan SGS
Vivekanandan SS Vivekanandan SS
Author Profile Icon Vivekanandan SS
Vivekanandan SS
Arrow right icon
View More author details
Toc

Table of Contents (14) Chapters Close

Preface 1. Part 1: Snowpark Foundation and Setup
2. Chapter 1: Discovering Snowpark FREE CHAPTER 3. Chapter 2: Establishing a Foundation with Snowpark 4. Part 2: Snowpark Data Workloads
5. Chapter 3: Simplifying Data Processing Using Snowpark 6. Chapter 4: Building Data Engineering Pipelines with Snowpark 7. Chapter 5: Developing Data Science Projects with Snowpark 8. Chapter 6: Deploying and Managing ML Models with Snowpark 9. Part 3: Snowpark Applications
10. Chapter 7: Developing a Native Application with Snowpark 11. Chapter 8: Introduction to Snowpark Container Services 12. Index 13. Other Books You May Enjoy

Setting up Snowpark Container Services

In this section, we’ll lay down the groundwork necessary for exploring Snowpark Container Services. We will use Docker to create an OCI-compliant image to deploy to Snowpark. We’ll start by creating Snowflake objects.

Creating Snowflake objects

To create Snowflake objects, follow these steps in Snowsight with the ACCOUNTADMIN role:

  1. Create a role named test_role using the following command. This role will be used for our Snowpark application:
    USE ROLE ACCOUNTADMIN;
    CREATE ROLE test_role;

    This will print the following output:

Figure 8.2 – A Snowflake role

Figure 8.2 – A Snowflake role

  1. Create a database and grant access to the database role by running the following command:
    CREATE DATABASE IF NOT EXISTS SNOWPARK_DEFINITIVE_GUIDE;
    GRANT OWNERSHIP ON DATABASE SNOWPARK_DEFINITIVE_GUIDE
      TO ROLE test_role COPY CURRENT GRANTS;

    This will display the following output:

Figure 8.3 – Granting access

Figure...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime