enum
CQL::Adapter
Overview
Represents a database adapter module.
Defined in:
cql.crEnum Members
-
SQLite =
0 -
MySql =
1 -
Postgres =
2 -
CockroachDB =
3
Instance Method Summary
-
#cockroach_db?
Returns
trueif this enum value equalsCockroachDB - #dialect : Expression::BaseDialect
-
#driver_uri(uri : String) : String
The scheme crystal-db's driver registry knows for this adapter's URIs.
-
#my_sql?
Returns
trueif this enum value equalsMySql -
#postgres?
Returns
trueif this enum value equalsPostgres -
#postgres_compatible? : Bool
PostgreSQL and CockroachDB share a wire protocol,
$nplaceholders and RETURNING. -
#sq_lite?
Returns
trueif this enum value equalsSQLite -
#sql_type(type) : String
Returns the SQL type for the given type.
Instance Method Detail
def driver_uri(uri : String) : String
#
The scheme crystal-db's driver registry knows for this adapter's URIs.
def postgres_compatible? : Bool
#
PostgreSQL and CockroachDB share a wire protocol, $n placeholders and RETURNING.
def sql_type(type) : String
#
Returns the SQL type for the given type. @param type [Type] the type @return [String] the SQL type Example Getting the SQL type
CQL::Adapter::SQLite.sql_type(Int32) # => "INTEGER"