User Tools

Site Tools


snc_table_maps

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
snc_table_maps [2018/09/05 22:48]
paul [Get Display Value]
snc_table_maps [2019/01/17 17:17] (current)
alvin.tan [Embedded Table Maps]
Line 217: Line 217:
  
 ===== Further Examples ===== ===== Further Examples =====
 +
 +
 +==== Related Records ====
 +Embedded table maps can be used to uphold related records in ServiceNow. This will allow users to embed child records into the parent payload to be restored on the receiving instance. ​
 +
 +{{:​embedded_problem.png?​1000|}}
 +
 +<​code>​
 +<​common_incident>​
 +       <​problems>​
 +             <​problem>​
 +                 <​short_description>​Problem Example</​short_description>​
 +                 <​assignment_group_name/>​
 +                 <​id>​7299dbc5db22230071f25421cf9619c1</​id>​
 +                 <​assigned_to_name/>​
 +                 <​state>​1</​state>​
 +                 <​number>​PRB0040104</​number>​
 +             </​problem>​
 +      </​problems>​
 +</​common_incident>​
 +</​code>​
 ==== Conversion to a New Format ==== ==== Conversion to a New Format ====
 To script the transformation of an entire record to a new format (ex: convert to a custom JSON format), select the ''​Use Script''​ checkbox on the Table Map configuration form.  This will display a Script input that will execute a script instead of using individual field mappings. ​ Use the ''​current''​ variable to reference values in the source record and set the ''​answer''​ variable to be the new value returned. ​ The following example builds a JSON string from the value of correlation_id and short_description in the current record: To script the transformation of an entire record to a new format (ex: convert to a custom JSON format), select the ''​Use Script''​ checkbox on the Table Map configuration form.  This will display a Script input that will execute a script instead of using individual field mappings. ​ Use the ''​current''​ variable to reference values in the source record and set the ''​answer''​ variable to be the new value returned. ​ The following example builds a JSON string from the value of correlation_id and short_description in the current record:
snc_table_maps.1536212919.txt.gz ยท Last modified: 2018/09/05 22:48 by paul