How can we help?

Snowflake Secure Data Sharing

Overview

With Snowflake’s Secure Data Sharing integration, you can gain instant access to valuable first-party user data generated from Cordial—directly in your designated Snowflake account. Cordial’s Snowflake portal gives you seamless, secure, and real-time access to your customer’s activity, orders, custom events, and profile data in an easy and frictionless way—all without the need for typical extract, transform, and load (ETL) data sharing solutions.

For Cordial customers on the Snowflake Data Cloud, this partnership will enable live access to your valuable first-party customer data, empowering you with the data agility to analyze engagement trends, monitor consumer behaviors, gauge performance, and unlock new insights about metrics driving your business. 

Use cases

  • Analyze behavioral patterns and generate funnel reports to better understand your customer’s buying behavior and patterns.
  • Leverage Cordial customer and event data alongside the rest of your Snowflake data to power feature sets within your application such as dashboards, attribution models, user predictions and recommendations, data visualizations, and more to enrich business insights.
  • Empower your business intelligence team by getting them the data they need without engineering.

What is Data Sharing?

Snowflake’s Secure Data Sharing is a proprietary way to allow businesses, like Cordial, to seamlessly grant and share data with partner client organizations—like you! Unlike traditional data sharing, Snowflake Data Sharing is far easier to use because it provides immediate access to ready-to-query data, eliminating friction and unnecessary cost that come with ETL processes.

How it works

With Secure Data Sharing, no actual data is copied, transferred, or exchanged between accounts, which eliminates data movement. All sharing is accomplished through Snowflake’s unique multi-cluster shared data architecture.

This is an important concept because it means that sharing data from Cordial to your Snowflake account does not take up any storage in your Snowflake consumer account—and therefore does not contribute to your monthly Snowflake data storage cost. The only charges are for the compute resources used to query on shared Cordial data. 

Benefits

  • Accelerate business insights: Engagement data, custom events, contact attributes, orders, cart items, and message sends are immediately accessible and query-able from the instant of arrival.
  • Share live data with ease: Securely and seamlessly share data across your organization through account-to-account shared views.
  • Replace traditional data sharing methods: Eliminate the need to move or copy data, rebuild schemas, or manage complex data pipelines.
  • Reduce cost: Shared data does not take up any storage in your Snowflake account, so you'll only pay for the compute resources used for queries on shared Cordial data.
  • Painless setup and secure access: Data engineering, storage, sharing, and governance all managed by Snowflake—resulting in turn-key setup and maintenance.
  • Cloud region support: Cordial hosts all user-level data for clients in the Snowflake AWS US-West-2 cloud region. Cordial can provide secure data sharing to any joint client for global Snowflake cloud regions across AWS, Google Cloud, and Microsoft Azure.

Request a secure share

If you're interested in having your Cordial customer data available in your Snowflake account, please visit Cordial's listing in the Snowflake marketplace to request a secure share and reach out to your client success manager. You may need to provide your Snowflake account information, which is available by clicking the Copy button in the Account Information dropdown, to help our team verify and provision your request. 

Once you've requested a secure share, Cordial will verify and provision the data share from our Cordial Snowflake account to your Snowflake account. After the share is provisioned, Cordial will notify you that your data share has been provisioned—and you'll need to follow the steps below to accept the secure share.

1. Your account administrator will need to log in to your Snowflake account, click on Shares in the top navigation bar, and accept the share request from Cordial.

2. To accept the share request, select the secure share and click Create Database from Secure Share

3. Your account administrator can then give the secure share a Database Name, select who can access the data, and leave any comments. 

4. You can then go to the Worksheets tab in the top navigation bar in your Snowflake instance and see the new Cordial shared database and shared dataset.

Data available

The following datasets are available from Cordial through a secure data share. Data is refreshed multiple times per day, giving you direct access to live customer data in near real-time. 

Data

View

Description

Contact attributes

contacts

Data specific to each contact such as name, address, etc. You can store string type (i.e. first name), number type (i.e. age), geo type (i.e. addresses), and array type (i.e. favorite colors). You can add as many attributes as needed to describe your contacts.

Cart items

contacts

Cart items are stored with each contact and can contain information about a product such as SKU, description image, and much more.

Events

contactactivity (events)

Data related to a contact's activity or behavior. This can be message activity as well as website activity (browsed a page, added to cart), or external (IoT) activity.

Message sends

messagesends

Data specific to message sends, such as the channel used to send the message, whether the message is promotional or transactional, information about how and when the message was created, and more.

Orders

orders

Data about a contact's order history.

Sample queries

The Snowflake data share allows you to build powerful queries to get the exact data you want. Here are two examples.

CONTACTS_VIEW

Here is an example query that uses the CONTACTS_VIEW to find (1) the grand total dollar amount of all cart items across all carts, (2) the average dollar amount of all cart items per cart, (3) the average number of items per cart, and finally (4) the total number of carts.

SELECT
 SUM(TRY_TO_NUMBER(cart:"totalAmount"::varchar)) as "grand_total_amount",
 AVG(TRY_TO_NUMBER(cart:"totalAmount"::varchar)) as "average_total_amount",
 AVG(ARRAY_SIZE(cart:"cartitems")) as "average_num_cart_items",
 count(*) as "total_carts"
FROM
 contacts_view
WHERE
 cart IS NOT NULL
;

grand_total_amount

average_total_amount

average_num_cart_items

total_carts

41479622

1595370.077

13.961538

26

This query demonstrates Snowflake’s support for querying structured data. In this case, the cart field is an object with several embedded keys such as totalAmount and cartitems (which is itself an array of zero or more nested item objects).

CONTACTACTIVITY_VIEW

Here is an example query that demonstrates selecting data from the CONTACTACTIVITY_VIEW. The query returns total daily counts for several events (aka actions) related to sending messages for a specified date range (message sends, opens, clicks, and bounces). This query makes use of some advanced SQL features such as Common Table Expressions and the PIVOT function, demonstrating Snowflake’s rich SQL support.

WITH action_totals AS (
  SELECT
    to_date(action_date) as action_date,
    action,
    count(*) as total
  FROM
    contactactivity_view
  WHERE
    action_date BETWEEN '2022-09-19' AND '2022-09-25'
    AND action IN ('message-sent', 'open', 'click', 'bounce')
GROUP BY
  action_date,
  action
)
SELECT
 *
FROM
 action_totals
PIVOT (
 SUM(total) FOR action IN ('message-sent', 'open', 'click', 'bounce')
) as p
ORDER BY
  action_date

ACTION_DATE

message-sent

open

click

bounce

2022-09-19

2749273

1080279

3015

2829

2022-09-20

2605236

1796475

7139

6229

2022-09-21

2738569

1884556

4742

2145

2022-09-22

3073

929171

1485

6047

2022-09-23

2810032

812085

2628

466

2022-09-24

2041732

1600629

4839

2258

2022-09-25

928

87

1

1

 

 

Comments

0 comments

Please sign in to leave a comment.