Data Preview from a Pipeline

Data Preview from a Pipeline

On this Page

Overview

Data Preview helps you confirm that mapping and transformations are working as expected. At design time, when you save or validate a Pipeline, SnapLogic passes a sampling of the real data through all of the Snaps. You can preview the sample data output from any Snap that executed successfully and navigate through all Data Previews in the Pipeline. You can also preview the sample data from failed Snaps that output error documents.

SnapLogic encrypts the sample data before storing it to use in Data Preview. By default, the sample data includes the first 50 records from the input source, up to 15 MB in total size. If the number of documents to preview exceeds 15 MB, validation causes an error. Org admins can change the Org-wide setting for the number of preview documents in Admin Manager or disable pipeline validation. If not disabled, users can change the number of preview documents at the Project level in their User Settings, up to the value set by the Org admin in Admin Manager.

The Data Preview opens in a table. You can display it in JSON format or raw, unformatted. You can also use DataViz to render specific fields of preview data in the following visualizations:

  • Pie chart - Organizes data in sectors, where each sector represents a group proportionate to the whole.

  • Line chart - Compares trends visually for multiple fields or a single field over time.

  • Bar chart - Compares a category from a data set, similar to a pie chart. The simple bar chart displays the number of instances for a field. The group and count bar chart compares data sets from two categories against an index, such as time or geographical location.

  • Scatter chart - Plots the data set for two fields as a map of coordinates and optionally aggregates the data by a third category.

Required Permissions

To view the data preview, you must have execute permissions to the pipeline. If you have read, write, or read and write permissions to the pipeline, the data preview does not display. Permissions to pipelines and other assets are assigned at the project level. Refer to Assign project permissions.

Limitations with Numbers in Data Preview

In preview data, number fields do not always display the expected values:

  • JavaScript has limitations in displaying numbers. The actual value is maintained in the data; however, the preview might not display the numbers accurately. For example:

    • Numbers greater than the JavaScript constant Number.MAX_VALUE display as Infinity. Learn more about MAX_VALUE.

    • Integers greater than the JavaScript constant Number.MAX_SAFE_INTEGER might be rounded or otherwise displayed incorrectly. Learn more about MAX_SAFE_INTEGER.

  • Numbers without significant fractional values are displayed as integers. For example: 10.00 is displayed as 10.

Previewing Data

After saving or validating a Pipeline, preview the data that a Snap will pass down the Pipeline using the data preview icon in the connector on the right side of the Snap:

Data preview

Open the Data Preview in one of the following ways:

  • On Windows, click the data preview icon. 

  • On MacOS, double-click the data preview icon.

To disconnect a Snap instead of displaying the data preview, position the cursor over the connection from the adjoining Snap.

By default, the data preview displays as a table. The Data Preview for some Snaps, such as file readers, displays the metadata instead of data values. The following example shows preview data values after passing through an Excel Parser Snap:

Data Preview Example

Use the controls on the Data Preview pane to:

  • Switch the data format to JSON or raw

  • Display preview document data formatted with line feeds

  • Download the preview data

  • Open DataViz to generate a chart from the preview data

  • Navigate through the preview data

  • Move to the Preview Data pane for the next or previous Snap

Navigating through Snap Data Previews

Use the outer arrows at the bottom left of the data preview to navigate to the results for the next or the previous Snap:

Navigate Snap Data Previews

Viewing data in error documents

If a Snap fails to execute, you can preview data from the previous Snap error documents:

Setting the Number of Records to Preview

You can change the number of records to be shown in the Data Preview, up to a total size of 15 MB. Depending on the size of individual records, increasing the number can provide better visualization.

To change the number of records: 

  1. In the IIP, click the dropdown next to your username to open the menu:

  2. Select User Settings to open the Settings dialog:

  3. In the Settings dialog, click the Preview Document Count drop-down menu, and choose from the available values.

  4. Click Save.

Using DataViz

Save or validate a Pipeline, and open Data Preview for a Snap. Click DataViz and drag the cursor to the left or click the triangle at the top of the DataViz bar to display chart options:

The following sections describe how to use DataViz to configure charts:

Pie Chart

Pie charts reveal patterns by totaling the unique values in a field. Select a field that does not contain too many values. For example, selecting a Grade key, where there are only 16 possible values, makes a meaningful pie chart. However, selecting a Date key over three years of transactions would result in too many dates for the pie chart visualization to render the chart correctly.

If the field you choose to visualize contains too many unique values, the pie chart might fail to render.

To display preview data in a pie chart:

  1. Open Data Preview for a Snap.

  2. Click the triangle at the top of the DataViz bar.

  3. For Chart Type, select Pie Chart.

  4. Click Key to Visualize and choose the key for the values to represent in a pie chart.

Line Charts

A line chart reveals data trends. DataViz can render preview data in a line chart:

Line Chart for Numeric Fields