Module types

Module types 

Source
Expand description

§Supported types

Rust typeExasol type
boolBOOLEAN
i8, i16, i32, i64DECIMAL
f64DOUBLE
String, &strCHAR(n) ASCII/UTF8, VARCHAR(n) ASCII/UTF8
ExaIntervalYearToMonthINTERVAL YEAR TO MONTH
HashTypeHASHTYPE
Option<T>T (for any T that implements Type)

§chrono feature

Rust typeExasol type
chrono::NaiveDateDATE
chrono::NaiveDateTimeTIMESTAMP
chrono::TimeDeltaINTERVAL DAY TO SECOND

§time feature

Rust typeExasol type
time::DateDATE
time::PrimitiveDateTimeTIMESTAMP
time::DurationINTERVAL DAY TO SECOND

§rust_decimal feature

Rust typeExasol type
rust_decimal::DecimalDECIMAL(p,s)

§bigdecimal feature

Rust typeExasol type
bigdecimal::BigDecimalDECIMAL(p,s)

§uuid feature

Rust typeExasol type
uuid::UuidHASHTYPE

§geo-types feature

Rust typeExasol type
geo_types::GeometryGEOMETRY

Note: due to a bug in the Exasol websocket API, GEOMETRY can’t be used as prepared statement bind parameters. It can, however, be used as a column in a returned result set or with runtime checked queries.

§json feature

The json feature enables Encode and Decode implementations for Json<T>, serde_json::Value and &serde_json::value::RawValue.

§Array-like parameters

Array-like types can be passed as parameters, including in compile time checked queries, for batch parameter binding due to Exasol’s columnar nature.

Supported types are Vec<T>, &T (slices), [[T;N]] (arrays), iterators through the ExaIter adapter, etc.

Parameter arrays must be of equal length (runtime checked) or an error will be thrown otherwise.

Custom types that implement Type can be used in array-like types by implementing the ExaHasArrayType marker trait for them.

Modules§

chronochrono
geo_typesgeo-types
timetime
uuid
Generate and parse universally unique identifiers (UUIDs).

Structs§

BigDecimal
A big decimal type.
Decimal
Decimal represents a 128 bit representation of a fixed-precision decimal number. The finite set of values of type Decimal are of the form m / 10e, where m is an integer such that -296 < m < 296, and e is an integer between 0 and 28 inclusive.
ExaIntervalYearToMonth
A duration interval as a representation of the INTERVAL YEAR TO MONTH datatype.
ExaIter
Adapter allowing any iterator of encodable values to be treated and passed as a one dimensional parameter array for a column to Exasol in a single query invocation. Multi dimensional arrays are not supported. The adapter is needed because Encode is still a foreign trait and thus cannot be implemented in a generic manner to all types implementing IntoIterator.
HashType
Newtype used for more explicit encoding/decoding of arbitrary length data into/from HASHTYPE columns.
Json
Json for json and jsonb fields
JsonRawValue
Reference to a range of bytes encompassing a single valid JSON value in the input data.
Text
Map a SQL text value to/from a Rust type using Display and FromStr.
Uuid
A Universally Unique Identifier (UUID).

Enums§

JsonValue
Represents any valid JSON value.

Traits§

ExaHasArrayType
Marker trait that limits arrays encoding to one dimensioanl arrays.
Type
Indicates that a SQL type is supported for a database.