Data types¶
The Database API client and the SQLAlchemy dialect use different Python data types. Consult the corresponding section for further information.
Table of contents
Database API client¶
This section documents data types for the CrateDB Database API client.
Caution
The CrateDB Database API client implementation is incomplete. For the time being, the client uses native Python types.
In general, types are mapped as follows:
CrateDB |
Python |
---|---|
When writing to CrateDB, the following conversions take place:
Python |
CrateDB |
---|---|
Note
The type that date
and datetime
objects are mapped depends on the
CrateDB column type.
SQLAlchemy¶
This section documents data types for the CrateDB SQLAlchemy dialect.
Type map¶
The CrateDB dialect maps between data types like so:
CrateDB |
SQLAlchemy |
---|---|
Object (extension type) |
|
ObjectArray (extension type) |
|
Geopoint and Geoshape (extension type) |
|
Geopoint and Geoshape (extension type) |