Skip to content

Data Types ​

In rekuiper, every column and expression has an associated data type that restricts valid values and available operations.

Supported Data Types ​

rekuiper supports the following data types:

NumberData TypeDescription
1bigint64-bit signed integer.
2float64-bit floating-point number.
3stringUnicode text characters.
4datetimeDate and time timestamp value.
5booleanBoolean value (true or false).
6byteaBinary byte array. In JSON streams, represent bytea fields as Base64-encoded strings.
7arrayOrdered list of scalar elements or nested struct values.
8structComplex object consisting of named key-value attributes.

Compatibility for Comparison and Calculation ​

Binary operations evaluate expressions in SELECT and WHERE clauses. If an expression combines incompatible operand types, rekuiper generates a runtime error and delivers the error message to configured sinks.

Arrays and structs cannot participate directly in arithmetic or comparison operations. The following compatibility matrix specifies permitted operations between scalar types:

Left Operandbigintfloatstringdatetimeboolean
bigintYesYesNoNoNo
floatYesYesNoNoNo
stringNoNoYesNoNo
datetimeYesYesYes (if formatted correctly)YesNo
booleanNoNoNoNoYes

The default parsing format for datetime strings is "2006-01-02T15:04:05.000Z07:00".

Null Value Handling ​

When an expression encounters a nil (null) operand:

  1. Any comparison against nil evaluates to false.
  2. Any arithmetic calculation with nil returns nil.

Type Conversions ​

Use the built-in cast(col, targetType) function to convert values between data types at runtime. Refer to transformation functions for usage details.

Released under the Apache-2.0 / MIT License.