Mappings > Mappings > Data preview for an elastic mapping
  

Data preview for an elastic mapping

When you create a mapping, you can preview data for individual transformations to test the mapping logic.
To preview mapping data, your organization must have the appropriate license.
You preview data for a transformation on the Preview panel of the transformation. Select the number of source rows to process and the runtime environment that runs the preview job.
When you run a preview job, Data Integration creates a temporary mapping task that contains a virtual target immediately downstream of the selected transformation. Data Integration discards the temporary task after the preview job completes. When the job completes, Data Integration displays the data that is transformed by the selected transformation on the Preview panel.
The following image shows the Preview panel of a Sorter transformation after you run a preview job on the transformation:
The mapping contains Source, Filter, Sorter, and Target transformations. The Sorter transformation is selected, and the Preview panel is displayed. The Preview panel shows the rows of data that have been processed by the Filter and Sorter transformations.
To preview data in a mapping, you must have the Data Integration Data Previewer role or your user role must have the "Data - preview" feature privilege for Data Integration.
You can preview data if the mapping uses input parameters. Data Integration prompts you for the parameter values when you run the preview.
You cannot preview data when you develop a mapplet in the Mapplet Designer. You cannot preview data that contains special, emoji, and Unicode characters in the table name.
Data preview behavior for elastic and non-elastic mappings can differ. Data preview content in this section is specific to elastic mappings.

Preview behavior for an elastic mapping

You can preview data if there are no mapping validation errors in the selected transformation. An elastic mapping shows preview data for the selected transformation. You can preview data for hierarchical data types.
You can preview data for any transformation except for the following transformations:
You can preview data for sources except for sources meeting the following conditions:
Data preview is available in an AWS environment.
A preview job runs on the same cluster as other elastic jobs. If the cluster is saturated with other jobs, the preview job can take longer to run and return data.

Running a preview for an elastic mapping

Run a data preview job on the Preview panel of the selected transformation. Data preview jobs run on AWS on-demand instances.
Before you run a data preview job for a elastic mapping, verify that there are no mapping validation errors in the selected transformation.
To run a preview job:
    1. In the Mapping Designer, select a transformation.
    2. Open the Preview panel.
    3. Click Run Preview.
    4. In the Run Preview wizard, enter the number of source rows to preview and the runtime environment to run the preview job.
    The number that you enter applies to each source in the mapping. For example, if you select 10 rows and the mapping contains multiple sources, the preview job processes the first 10 rows in each source.
    You can select up to 999,999,999 rows.
    Warning: Selecting a large number of source rows can cause storage or performance issues on the Secure Agent machine.
    5. Select the Read Entire Source option if you're sure you want Data Integration to read all source data. Preview data may be slow to display if you have a large source data set. Target data will be limited based on the value entered in the Rows to Preview field.
    6. The Enable Upstream Preview option allows you to preview data for the selected transformation and upstream transformations. This option is enabled by default. Preview data may be slow to display if you have many upstream transformations.**
    7. Click Run Preview.
Data Integration displays the results in the Preview panel for the selected transformation.
You can monitor preview jobs on the My Jobs page in Data Integration and on the All Jobs and Running Jobs pages in Monitor. Data Integration names the preview job <mapping name>-<instance number>, for example, MyMapping_1. You can download the session log for a data preview job.
To restart a preview job, run the job again on the Preview panel. You cannot restart a data preview job on the My Jobs or All Jobs pages.

Viewing preview results for an elastic mapping

Data Integration Elastic generates preview results for the selected transformation in the elastic mapping. Data Integration Elastic stores preview results in JSON files in the staging location configured in the elastic configuration.
Data Integration Elastic shows complex data cells as hyperlinks on the Preview page. When you click a hyperlink, the preview data displays in a separate panel.
The following limitations apply to the preview results:
Data Integration Elastic purges the preview data once every 30 minutes to delete these data files. Data Integration Elastic also deletes preview data when a Secure Agent stops a cluster.

Customizing preview results for an elastic mapping

You can choose which columns to display on the Preview panel. You can also reorder the columns. Customize the Preview panel on the Settings dialog.
The following image shows the Settings dialog:
The image shows an Available Columns area on the left and a Selected Columns area on the right. Column names appear in both areas. The column MiscDate is selected in the Selected Columns area. There are directional arrows to move the selected column to the Available Columns on the left, or to move it up or down in the Selected Columns area.
To open the Settings dialog, click the settings icon on the Preview panel. Columns in the Selected Columns area appear on the Preview panel. To hide a column from the Preview panel, select it and move it to the Available Columns area. To reorder the columns in the Preview panel, select a column name in the Selected Columns area and move it up or down.