Technology Blog Posts by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 
Aman_V
Product and Topic Expert
Product and Topic Expert
1,562

Welcome to the fourth installment of our "SAP Integration Suite – Connect Everything" blog series. In this edition, we'll be exploring the transformative potential of integrating Snowflake, a leading cloud data warehouse solution, with SAP Cloud Integration, a powerful integration platform-as-a-service (iPaaS) within the SAP Integration Suite through its native Snowflake adapter.

Pre-Requisites 📝

This blog focuses on the integration with Snowflake through the native Snowflake Adapter of SAP Cloud Integration to be used as a receiver. The availability of the adapter is dependent on the SAP Integration Suite service plan. For more information about different service plans and their supported feature set, see SAP Notes 2903776 and 3188446 . To read more on this adapter refer the help documentation

For other service plans the connectivity can be established through the traditional Open Connectors Snowflake Rest API .

Snowflake trial account has been used for the Demo.

🚨 Caution 🚨

Mass data exchange operations (whether or not external staging is used) can have a significant impact on the performance of your SAP Cloud Integration tenant. Before proceeding with large-scale data transfers, we strongly recommend thoroughly assessing and analyzing the current health and capacity of your tenant to ensure stable and efficient operation.

Additionally, leveraging data compression techniques such as GZIP has proven to substantially enhance performance during mass data exchanges using external staging. We encourage you to implement compression where possible to optimize throughput and minimize resource consumption.

Introduction

As businesses strive to harness the power of data-driven decision-making, the ability to seamlessly connect cloud-based data warehouses and enterprise applications has become a strategic imperative. By diving deep into the technical details and best practices, we will uncover the remarkable benefits that the Snowflake integration can bring to your enterprise ecosystem.

What is Snowflake...?

Snowflake is a modern cloud native data warehouse solution that has gained significant attention in the enterprise data management landscape. Its architecture is designed to provide scalability, flexibility, and performance for organisations managing large and diverse data sets.

What is SAP Cloud Integration...?

As a key component of the SAP Integration Suite, SAP Cloud Integration plays a vital role in connecting various SAP and non-SAP systems within the Enterprise ecosystem. As a powerful iPaaS solution, SAP Cloud Integration offers a comprehensive set of integration capabilities, including data integration, process integration, and API management.

What is the advantage...?

By leveraging SAP Cloud Integration and its prepackaged Out-of-the-box benefits, organizations can seamlessly connect Snowflake with their existing SAP applications, such as SAP IBP(Integrated Business Planning), SAP ERP, SAP Analytics Cloud and SAP S/4HANA or Non-SAP applications. This integration allows for the efficient exchange of data, the automation of business processes and the creation of data-driven insights that can drive strategic decision-making.

I would like to re-iterate the native Snowflake adapter highlights as described in the official documentation (please refer this documentation to check for the most recent features)

  • Bulk Export and Import: Supports reading files from multiple input formats like CSV, JSON, and Avro. Export data to your desired format using unload operation.
  • Snowflake Operations Support: Snowflake Adapter offers support for all Snowflake operations along with extended SQL support for advanced users.
  • Ease of Access and Connectivity : Snowflake adapter allows you to save connection related details on our platform which simplifies operations and querying on your part.
  • Multiple options for Staging Storage: Snowflake Adapter provides various options to load data into staging storage like Amazon S3, Google Cloud Storage, or Microsoft Azure configured in Snowflake.
    02_02_0020.png
  • Secure Authentication: Provides secure authentication with Database Account and Key-Pair options.

What's the High Level Architecture...?

With the release of the native Snowflake adapter SAP Cloud Integration has unlocked the out of the box capability to integrate with Snowflake databases either with or without external staging for mass data exchange.

AmanVarshney_1-1745743968988.png

What are the Steps to Configure...?

Let's explore the step-by-step configurations required to establish a successful connection between the two platforms.

Step 1

Fetch the required Snowflake details based on the chosen Authentication Type.

Step 2

Copy Prepackaged Adapter from the Discover section

AmanVarshney_5-1745415875662.png

Step 3

 Deploy the copied adapter from Design section

AmanVarshney_6-1745416071397.png

Step 4

Once deployed the adapter is available to be used to integrate Snowflake as receiver

Configure the connection details

  • Database Account Type authentication
    AmanVarshney_7-1745784038291.png

     

  • Key-Pair Authentication (Refer the section 3.3.2 Creating Keystore for Key-Pair Authentication in the descriptive documentation link shared below)
    AmanVarshney_6-1745783245307.png

    Please refer the descriptive official documentation for steps to generate Keystore(JKS file) 

    AmanVarshney_7-1745417849987.png
Alternative Approach to create Keystore (RSA Key) Private key alias in SAP Cloud Integration through PEM file followed in this demo
  • Run the commands in the below sequence in SnowSQL/OpenSSL to create encrypted private key(.p8) and public key(.pub). You will be asked to create a pass phrase for the private key and will be needed in the later steps while using this private key.
    openssl genrsa 2048 | openssl pkcs8 -topk8 -v2 des3 -inform PEM -out rsa_key.p8
    AmanVarshney_1-1745781613998.png
    openssl rsa -in rsa_key.p8 -pubout -out rsa_key.pub
    AmanVarshney_2-1745781758063.png
  • Assign this public key to the user through SQL query run in Snowflake
    ALTER USER SnowflakeDemo SET RSA_PUBLIC_KEY='MIIXXX';
  • For the next steps I would like to give a disclaimer that I am not an expert in openssl and its a quick trial browsing online to generate pem key (with RSA private key header) from encrypted p8 key. Please feel free to comment if it can be simplified.
    Run below steps to create pem key
    openssl pkcs8 -in rsa_key.p8 -outform DER -inform PEM -out snowflake.der
    openssl rsa -inform DER -in snowflake.der -outform PEM -out snowflake_rsa.pem
    AmanVarshney_3-1745782630871.png

  • Use the generated snowflake_rsa.pem file in creating a RSA Key Keystore Alias in SAP Cloud Integration.
    AmanVarshney_5-1745782986673.png AmanVarshney_4-1745782892289.png
Step 5

Configure the Processing details in the adapter configuration for various operations supported. The configuration details for these operations are well explained in the official documentation.

Below is the distinction of the bulk operations that can only be used with External staging. You can refer the external staging steps documented for Amazon S3 as a part of SAP TechEd 2024 - IN280 session (SAP IBP - Snowflake integration). Watch out the IN280 session video here

With External Staging
  • Bulk Upsert
  • Unload
    AmanVarshney_3-1745786224439.png
    The sequence of calls from SAP Integration Suite(SAP Cloud Integration)
Without External Staging
  • Delete
  • Execute
  • Insert
  • Select
  • Table List
  • Update
Step 6

Deploy and run the IFlow through self-timer or external trigger to cherish the mere lookup or mass data exchange efficiency from Snowflake.

What are your experiences with Snowflake integration in SAP? Would love to know your thoughts, adventures and use cases in the comments! 🤠

Stay tuned for the next installment of our "SAP Integration Suite – Connect Everything" series, where we will explore even more exciting integration scenarios and capabilities within the SAP Integration Suite.