...
schema:
The list of requested attributes (keys) and their data type.
type:
The type of the output tuplekeepInput:
If set to true, the key-value is stored in the additional content container of the output tuple.dateFormat:
Can be used to format the timestamp. To create a timestamp an attribute of data type STARTTIMESTAMP or ENDTIMESTAMP has to be added to schema.
...
Code Block | ||||
---|---|---|---|---|
| ||||
out = KEYVALUETOTUPLE({
schema=[['Name', 'Double']],
type='Measurement',
keepinput='false'
},
in
) |
Example 2
Assume that a data source in sends key-value-pairs about persons in the following (JSON-)format:
Wiki Markup |
---|
{person.name="Max", person.age=22, timestamp=11123} |
Then, reading the name (and timestamp) is as follows:
Code Block | ||||
---|---|---|---|---|
| ||||
out = KEYVALUETOTUPLE({
schema=[['person.name', 'String'], ['timestamp', 'STARTTIMESTAMP']],
type='Measurement',
keepinput='false'
},
in
) |
...