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
As part of

Overview

The mapping table in the Mapper Snap , the mapping table makes it easier enables you to do the following:

  • Determine which fields in a schema are mapped or unmapped.
  • Create and manage a large mapping table through drag-and-drop.
  • Search for specific fields.


Info
titleWhen you use the Mapper, ensure the following:

...

  • If an XML schema is exposed in the Target schema column of the Mapper Snap, map the attribute fields

...

  • before the element fields of the enclosing element field.

...

  • The mapping ensures that the JSON

...

  • data from the Mapper Snap is valid for converting to XML.
  • If a Copy Snap is placed directly after a Mapper Snap, schema

...

  • information is not visible in the target schema of the Mapping Table.

Automatically

...

Map Fields

To let the SnapLogic Platform make the best effort at mapping, click AutoLink. See Refer to AutoLink for more information. To manually map fields:

  1. Click  to add a row, then drag a field Drag an element from the Input Schema into the empty field. Doing so changes Expression field of the Mapping table to change the input to an expression.
  2. Drag the appropriate output schema Output Schema field into the target path for the corresponding input schema Input Schema field. If a value already exists, the new value replaces it.

To merge two input fields into one output, you can select and drag one field out, then drag another input field into the same Expression field and they are combined.Image Removedeach input field, one at a time, onto one common Expression field. The system combines the two fields into one.

Image Added

 To insert a new line between entries, use the unicode Unicode value of \u000A, as in:
 $element + "\u000A" + $element 

To directly map a field from one schema to the other, click and drag the field from either schema over to the other schema , and the mapping is automatically created. You can also drag fields from the input schema to the target path.

Target Mapping Schema

The schema generated by a downstream Snap populates a list of suggestions for the Expression column. Available when the New Form UI is enabled through the User Settings dialog in SnapLogic Designer, this This functionality is useful when the Mapper Snap is followed by Snaps with custom fields, such as the JSON Formatter or NetSuite Snaps.

...

Toggle off the Expression button in the Expression Builder, then select the field with multiple keys, and a dropdown list of the multiple keys in that field.
Image RemovedImage Added

...

Select Multiple Fields in a Schema

You can use any of the following features to select multiple fields in an Input or Target schema:  

  • Select All: Click this button to select all fields in a schema, including the collapsed children.
  • Deselect All: Click this button to deselect all currently-the selected fields in a schema, including the collapsed children.
    To select (or deselect) a subset of the schema, you can search for a the key name first, then click . Click Select All or (or Deselect All. In this case, select and deselect only apply ). Note that select (or deselect) applies only to fields that match the search terms.
  • Shift-click: You can also use a keyboard shortcut to select a range of fields. Select the first field in the range, hold down the Shift key, then select the last field in the range. You can also hold down the Shift key and click a plus symbol + in the schema hierarchy to fully expand that part of the hierarchy.

...

Use the Mapping Table (Data Preview)

By Preview your input and target schemas by clicking the arrow under the mapping table, you can get a preview of what your input and target schemas look like.

Note

The Expression builder preview is driven by the Dynamic Validation option in SnapLogic Designer User Settings.

...

Note

Non-expression targets  (= toggle off) are treated as literal values and do not impact the mapped/unmapped field list.

...

Search a Schema

...

in Mapper

To search for a specific field in either the input or target schema, enter the term specific field name in the appropriate search field. You can use the file path wildcards * and ? in a search. 

 Because searches are based on full key names, not just the node title, searches may might also select a node's ancestry. For example, if you have a tree such as:

...

Searching for "Parent" returns all three items since because the key names are $Parent, $Parent.Child, and $Parent.Child.Grandchild.

...

Select Multiple Fields in a Schema

As of the Winter 2018 release, you You can use these features to select multiple fields in an Input or Target schema:  

  • Select All: Click this button to select all the fields in a schema, including the collapsed children.
  • Deselect All: Click this button to deselect all currently-the selected fields in a schema, including the collapsed children.
    To select (or deselect) a subset of the schema, you can search for a key name first, then click Select All or Deselect All. In this case, select and deselect only apply to fields that match the search terms.
  • Shift-click: You can also use Use a keyboard shortcut to select a range of fields. Select the first field in the range, hold down the Shift key, then and select the last field in the range. You can also hold down the Shift key and click a plus symbol + in the schema hierarchy to fully expand that part of the hierarchy.

Watch the videos: 
SelectAllSelect-All-Deselect-All.mp4
ShiftClickShift-Click.mp4
Image Removed
 Image Added

...

View Mapped and Unmapped Fields

To filter whether to see all All, mapped Mapped, or unmapped Unmapped fields, use the drop-down dropdown next to the search field.: 

Image RemovedImage Added


 Additionally, once When a field is mapped, it the field is bolded and the color is changed if you are viewing made bold and highlighted when you view All.

Image RemovedImage Added

If When you click the mapped field in the schema, the row in the mapping table and the target are highlighted.

Image Removed

If an array of data is coming into the Mapper (Data) Snap, when you drag them into the table, a JSONPath expression is created to handle it.
Image Removed

Data Preview

By clicking drag the data from the input schema into the mapping table, you can use JSONPath expressions to transform the data. Image Added

Data Preview

Click the arrow under the mapping table , you can get a preview of what to preview the input and target schemas look like.:
Image RemovedImage Added

Other Usability Functions

  • You can collapse Collapse the schema views using with the gray arrows in the header row to give you for a larger Expression and Target path columns.
  • Click the down arrow within in an expression field to access the expression editor, functions and properties, and the upstream schema. Click the bubble in the Target path field to access the downstream schema suggestions.
  • You can rearrange Rearrange the rows within in the mapping table by:
    • Highlighting the left side, clicking, and dragging.
      Image RemovedImage Added
    • Mousing over a row until a selection arrow appears, then dragging it to a new location.
      Watch the video: Move.mp4

...