Skip to content
English
  • There are no suggestions because the search field is empty.

CONCAT() Function: combine several variables

The CONCAT() function combines multiple values into a single string. It is useful for constructing clinically meaningful composite variables from existing data.


It can be used with:

  • List (categorical) variables

  • Numeric variables

  • Event variables

  • As part of a sub-expression inside another function


Syntax


CONCAT(value1, value2, ...) 

All inputs are converted to text and concatenated in order.


Clinical Examples


1️⃣ Combining categorical variables

  • Side = Right

  • TearSeverity = Massive


CONCAT(Side, TearSeverity) 

Result:

RightMassive 


Important note: For List variables, a new modality RightMassive is automatically created if it does not already exist.


2️⃣ Combining numeric variables


CONCAT(1, 2)

Result:

12 


3️⃣ Building a date string from numeric fields

If you store:

  • Day (numeric)

  • Month (numeric)

  • Year (numeric)


You can write:

EVENT(CONCAT(Day, '/', Month, '/', Year)) 

This creates a properly formatted date string that can be used inside another function such as EVENT().


Key Points

  • If used in a list dynamic variable, new concatenated modalities are created automatically.

  • It can be nested inside other expressions.