Creating scripts

This topic describes the creation of scripts in relational modeling. Scripts can also be run from ION API, in an ION data flow, for example.

Custom settings can be used to parameterize load queries, scripts, and cube mappings, using the syntax @CustomSettings.<setting_name>.

Scripts can be SQL or non-SQL.

  1. Select Dashboards > Data Integrations > Relational Modeling.
  2. Select the database in the Target Connection list. In the Application list, select the application that contains the scripts to administer.
  3. Click Scripts.
  4. Click Add.
  5. Specify a name for the script or accept the default.
  6. Optionally, specify a description of the script.
  7. Specify your script in the Script Editor and click Validate.
    The Object Browser displays the target connection, its tables and their columns and their metadata. Double-click columns to add them to scripts. For reference only, the structure of the Integration table is displayed.
    Note: Scripts can be parameterized with the use of custom settings. Relational modeling automatically translates custom settings to SQL parameters. This eliminates the risk of SQL-injection.
    Use this syntax to incorporate a custom setting into a script:
    @CustomSettings.<setting_name>
    For example:
    delete * from Table where ModifiedDate > @CustomSettings.LoadFromDate