sqlload 0.5.1

SQL data loading tooling. Pre-release, under development.
/// The portable type names, as suggested in error messages.
pub const PORTABLE_NAMES: &[&str] = &[
    "bool",
    "smallint",
    "int",
    "decimal(p,s)",
    "float",
    "text",
    "varchar(n)",
    "date",
    "time",
    "timestamp_tz",
    "timestamp_ntz",
    "json",
    "uuid",
    "binary",
    "native(\"...\")",
];

/// The largest decimal precision every supported warehouse can hold.
pub const MAX_DECIMAL_PRECISION: u8 = 38;

/// Timestamps and times are carried at microsecond precision, the finest every warehouse shares.
pub const TIME_PRECISION_DIGITS: u8 = 6;

/// The most fractional-seconds digits any warehouse accepts in a time type's precision.
pub const MAX_FRACTIONAL_SECONDS_DIGITS: u8 = 9;

/// The bare name whose meaning (with or without a time zone) differs between warehouses.
pub const AMBIGUOUS_TIMESTAMP_NAME: &str = "timestamp";

/// Field metadata key marking a text column's portable type when Arrow has no matching type (`json`, `uuid`).
pub const ARROW_TYPE_METADATA_KEY: &str = "sqlload.type";

/// Digits an `int` needs: 64-bit integers have up to 19.
pub const INT_DIGITS: u8 = 19;

/// Digits a `smallint` needs.
pub const SMALLINT_DIGITS: u8 = 5;

/// Characters in a hyphenated UUID.
pub const UUID_TEXT_LENGTH: u32 = 36;