1. Home
  2. Integrations
  3. Concat Function

Concat Function

See how to use the Concat function

The Concat function joins (concatenates) multiple values into a single character sequence (string):

This function is widely used to create texts by combining literal variables or values from other operations.

In Sensedia Integrations, the Concat function is available for:

Example 1

Consider an integration with a step that generates a sales report. The goal is to create a message with the total units sold in 2023. For example:

  • In 2023, total sales of 5000 units.

To create the message, we will use:

  • The payload from a connector available in Properties: $.Sales.Response.Payload.totalSales.
  • Strings: represented between double quotes:
    • "_In_", "_total sales of_", "_units_"
    • " " (blank space)
    • "," (including comma as text).
  • Separators: the comma separates the elements or fields to be concatenated.
  • Numbers: 2023 (not placed in quotes).

Thus, we have the Concat function:

Example 2

Consider an integration that contains a SQL database connector:

IMPORTANT

To assemble SQL database instructions, you must use SQL syntax.

The SQL statement below selects all columns from a table only for the record where the id field value matches the id field value provided in the specified payload.

See the step-by-step of the instruction:

  • "SELECT * FROM clients WHERE id = ": instructs the database to:
    • Select (SELECT)
    • all columns (*)
    • from (FROM)
    • the clients table
    • and filter the search (WHERE)
    • to return only the record where the id column matches a specific value indicated after the equals sign (id =).
    • $.clientRegistration.Response.Payload.id: value that will be filtered by the instruction, extracted from the id field in the response payload of the clientRegistration connector.

Now, the value of the id field will be a fixed value equal to 155.

This means that the instruction will return all columns from the clients table for the record whose id is 155.

How happy are you with this page?

We use cookies to enhance your experience on our site. By continuing to browse, you agree to our use of cookies.Learn more