Transform Data

  • concept
Operational Insights can apply lightweight transformations to data as it’s ingested into a remote collection, before the data is stored.

You do this by creating a TRANSFORM FUNCTION — a specialized SQL++ user-defined function (UDF) that receives each incoming document and returns the transformed version to be stored. Common transformations include renaming or excluding fields, flattening nested structures, converting data types, and deriving new fields from existing ones.

Once you’ve created a TRANSFORM FUNCTION, you apply it to a remote collection using the APPLY FUNCTION clause of the CREATE COLLECTION statement, so that Operational Insights transforms each document automatically as it arrives, before storing it.

For the full syntax, requirements, and examples, see Transform Functions.