Add Current Timestamp
Description
Add a new field with the timestamp of the moment the transformation is run. This timestamp will be the same for records within a batch.
Parameters
- New Field Name: Specify the name of the new field to generate. This field name must not already exist in the schema.
- Output Format: Specify the date format to generate.
Input Requirements
Input schema may be any format.
Expected Output
Adds a field of type String.
Example
// Input
// New Field Name = "month"
// Output Format = "yyyy-MM"
{
"id": 1,
"event_name": "checkout"
}
// Output
{
"id": 1,
"event_name": "checkout",
"month": 2023-04
}