RisingWave supports a variety of protobuf data types, which are converted to equivalent types in RisingWave. This page provides an overview of the supported protobuf types and their corresponding RisingWave types.
Protobuf type | RisingWave type |
---|---|
any | jsonb |
double | double precision |
float | real |
int32 | int |
int64 | bigint |
uint32 | bigint |
uint64 | decimal |
sint32 | int |
sint64 | bigint |
fixed32 | bigint |
fixed64 | decimal |
sfixed32 | int |
sfixed64 | bigint |
bool | boolean |
string | varchar |
bytes | bytea |
enum | varchar |
message | struct . See details in Nested messages. |
messages_as_jsonb | jsonb . See details in Handle recursive definitions. |
repeated | array |
map | map . See details in Map. |
google.protobuf.Struct | Not supported |
google.protobuf.Timestamp | struct<seconds bigint, nanos int> |
google.protobuf.Duration | struct<seconds bigint, nanos int> |
google.protobuf.Any | struct<type_url varchar, value bytea> |
google.protobuf.Int32Value | struct<value int> |
google.protobuf.StringValue | struct<value varchar> |
struct<id int, name varchar>
in RisingWave.
messages_as_jsonb
with full type name separated by comma can solve the case. For example: