Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

On this Page

Table of Contents
maxLevel2
excludeOlder Versions|Additional Resources|Related Links|Related Information

Overview

The SAP Analytics Cloud Upsert Snap is a Write type Snap that can be used for updating/inserting (upserting) records into dimensions, fact tables, and public dimensions. The Snap accepts document input and produces document output so Snaps that have a document input/output can be used downstream/upstream of this Snap. The SAP Analytics Cloud Upsert Snap also supports batching to provide an efficient processing and performance.


Info
titleFact table - Append Vs Upsert

Two Snaps in this Snap Pack are currently used for adding data into a fact table - SAP Analytics Cloud Create and SAP Analytics Cloud Upsert. The SAP Analytics Cloud Create Snap lets you append records into an existing fact table (append/clean and append) while the SAP Analytics Cloud Upsert Snap lets you update records in an existing table (probably update a measure/dimension member) or insert a new record.

Prerequisites

A valid SAP Analytics Cloud account with appropriate read and write access.

Configuring Accounts

This Snap uses account references created on the Accounts page of SnapLogic Manager to handle access to this endpoint. See Configuring SAP Analytics Cloud Accounts for information on setting up this type of account.

Configuring Views

Input

This Snap has exactly one document input view.
OutputThis Snap has exactly one document output view.
ErrorThis Snap has at most one document error view and produces zero or more documents in the view.
Limitations and

Support

Known Issues

  • The output fields will be in string format so any processing on the output data must be done keeping this in mind, alternatively you may convert the output string into the appropriate data-type for your processing needs

Modes



Snap Settings


LabelRequired. The name for the Snap. Modify this to be more specific, especially if there are more than one of the same Snap in the pipeline.
Request type

The SAP Analytics Cloud object where the data is to be upserted. Currently, the Snap supports upserting data into the following objects:

  • Dimension members
  • Fact table
  • Public dimension members

Default value: Dimension members

Model ID

Conditional. The model ID of the target model for which the fact table is to be created. This is a suggestible field and the Snap suggest's IDs of all the models based on the account settings.

Default value: [None]


Note

Model ID is required only when upserting into the following objects:

  • Dimension members
  • Fact table


Dimension ID

Conditional. The dimension ID for the dimension in the SAP Analytics Cloud instance. This is a suggestible field and lists out all the dimensions for a specific model. This property is required only when deleting dimension members, for deleting fact tables the model ID is sufficient.

Default value: [None]


Note

Dimension ID is required only when upserting into the following objects:

  • Dimension members
  • Public dimension members


Batch size

Number of documents to be processed per batch. The smallest value that can be specified here is 1. The output is segregated per batch.

Default value: [None]

Multiexcerpt include macro
nameSnap Execution
pageSOAP Execute


Multiexcerpt include macro
nameExecution_Detail_Write
pageSOAP Execute



Examples


Upserting Dimension Members from Incoming Documents

The pipeline below shows how dimension members are upserted into a specified dimension within a model from incoming documents:

Input data is provided as a JSON document from the JSON Generator Snap, the screenshot below shows the input records:

Image Modified

The Mapper Snap is used to map the objects in the input records with the dimensions and measures in the target model. The SAP Analytics Cloud Create Snap is configured as shown below:

Batch size is 2 and the Request type is Dimension members so the input records are upserted to the model likewise - in two batches where the first batch has two records and the last batch has one record. A preview of the output from the Snap is as shown in the screenshot below:

 The exported pipeline is available in the Downloads section below.

Downloads

Attachments
patterns*.slp,*.zip



Insert excerpt
SAP Analytics Cloud Snap Pack
SAP Analytics Cloud Snap Pack
nopaneltrue