Skip to Content

Create a CRUD/Cram rule in Jitterbit App Builder

Introduction

A CRUD/Cram rule is a business rule with Purpose equal to CRUD, and Action equal to Cram. Such a rule "crams" data into the destination by inserting only the new records and silently skipping any duplicates. (Compare this to a CRUD/Insert rule (Purpose=CRUD, Action=Insert) which fails when trying to insert duplicate records.)

CRUD/Cram rules are useful for adding data from an API or other server connection imports, when you want new records to be added and existing ones to be skipped, and you can schedule them if you want them to run whenever the external data source imports new data.

Create a CRUD/Cram rule

To create a CRUD/Cram rule, follow these steps:

  1. Open your app and select > App Workbench > Tables.

  2. Select the table to be the target for data, then click the Publish to Business Layer button.

  3. Select App Workbench > Rules.

  4. Click the + Rule button.

  5. In the Rule panel, set the following fields:

    • Name: Enter a name for the rule.

    • Purpose: Select CRUD for data coming from the same data source, or XP CRUD for data coming from another data source. (Other options appear depending on your choice.)

    • Action: Select Cram.

    • If Purpose is XP CRUD, these two fields appear:

      • Source Data Source: Select the data source where the data comes from.

      • Target Data Source: Select the data source where the data is going to.

    • Target Layer: Select Data Layer.

    • Target: Select the target table.

  6. Click the Create button.

Define a CRUD/Cram rule

To define the CRUD/Cram rule, follow these steps:

  1. Use the + Tables button to add the originating and destination data sources, and any other sources you may need in your destination data source.

  2. Use the + Column button to add source and target columns:

    • Add at least one column with a Target Type of Bind. For CRUD/Cram rules, these columns are used to look up existing data in the destination table (serving the same purpose as a table's primary key columns).

    • Set Target Type to Target to define which source columns go to which destination columns when data is inserted into the destination table.

  3. Click the Validate button.

  4. (Optional) Check the results of the rule in the Results tab.