0

Add Record

Description

This part offers an easy way to insert a new record into a data table in the database.

Use

You can use this part to add new record to a data table in the database and return the row id of the inserted record. To insert multiple records use the Add Records part, or create a Loop to cycle through an array and use Add Record on each cycle.

Editor Fields

Tab

Field Name

Description/Use

Type/Options

Optional/Mandatory

Basic

Data object

This is the data object in which to store the id of the inserted record. Leave this field empty if your application does not require the returned row id.

Text

Optional

Basic

Group

This is the name of the collection in which the data object is stored.

Text

Optional

Basic

Data source

This is the name of the table into which the data should be saved.

Text

Mandatory

Basic

Replace if already exists

When this checkbox is checked, the system should update the existing record if it exists instead of inserting as a new record.

Checkbox

Optional

Basic

Columns

This is where you specify the column into which a record should be inserted and the value that should be inserted. The value to insert can be either a static value or an interpolated parameter from the session context. If you do not include the id column as one that should be added, the system will automatically increment the table index.

Tip: Use the $(...) construction to reference a variable from your application as the value to be stored in the column; for example, $(firstname).

You can also specify a default value if the variable is null by using $(data_object:default-value); for example, $(company_name:not specified).

Collection

Mandatory

Basic

Log data object

This is the data object that stores error messages from the execution of the database parts: add data record, get data record, update data record, delete data record, and import values. If the log data object is specified, the system will store the error message and stack trace of a database part to the object in case of errors.

When used by multiple database parts, the Log data object stores the cumulative list of error messages from the different parts.

Text

Optional

Basic

Reset log data object

When this is checked, the system will clear the error messages from the Log data object. Typically, this option should be checked in the first database part of a sequence of database parts.

Checkbox

Optional

Basic

Skip on error

When this is checked, the system will skip the execution of subsequent database parts linked to the same Log data object. 

Checkbox

Optional

Configuration Options

There are no configuration options associated with this part.

Examples

Download and import one of the example projects in your workspace.

Reply Oldest first
  • Oldest first
  • Newest first
  • Active threads
  • Popular
Like Follow
  • 4 mths agoLast active
  • 28Views
  • 3 Following

Home