Supported Data Types

Supported Data Types

Viewing typescript

switch to python

The schema defines the names and data types of the properties in your Data Model. Moose uses this schema to automatically set up the data infrastructure, ensuring that only data conforming to the schema can be ingested, buffered, and stored.

Key<T>

The Key type is specific to Moose and is used to define a primary key (opens in a new tab) in the OLAP storage table for your Data Model. If your Data Model requires a composite key, you can apply the Key type to multiple columns.

Supported Data Types

Moose supports various data types for Data Models, as summarized in the table below:

ClickhouseTypescriptMoose
StringString
BooleanBoolean
Int64Number
Int256BigInt
Float64Number
DecimalNumber
DateTimeDate
JsonObject
Bytesbytes
EnumEnum
ArrayArray
nullablenullable
Disclaimer

All Typescript number types are mapped to Float64

Key Type is Required

If you do not specify a Key type, you must set up a DataModelConfig to specify the properties that will be used for the order_by_fields. Learn more about DataModelConfig.