Skip to main content
Skip to main content
Edit this page

Supported data types

MongoDB stores data records as BSON documents. In ClickPipes, you can configure to ingest BSON documents to ClickHouse as either JSON or JSON String. The following table shows the supported BSON to JSON field type mapping:

MongoDB BSON TypeClickHouse JSON TypeNotes
ObjectIdString
StringString
32-bit integerInt64
64-bit integerInt64
DoubleFloat64
BooleanBool
DateStringISO 8601 format
Regular Expression{Options: String, Pattern: String}MongoDB regex with fixed fields: Options (regex flags) and Pattern (regex pattern)
Timestamp{T: Int64, I: Int64}MongoDB internal timestamp format with fixed fields: T (timestamp) and I (increment)
Decimal128String
Binary data{Data: String, Subtype: Int64}MongoDB binary data with fixed fields: Data (base64-encoded) and Subtype (type of binary)
JavaScriptString
NullNull
ArrayDynamicArrays with homogeneous types become Array(Nullable(T)); arrays with mixed primitive types are promoted to the most general common type; arrays with complex incompatible types become Tuples
ObjectDynamicEach nested field is mapped recursively
Info

To learn more about ClickHouse's JSON data types, see our documentation.