Documentation
¶
Index ¶
- Constants
- Variables
- func CheckClickhouseTables(cConn *Adapter, tables map[TableName]*TableProp)
- func Connect1(user, pass, host, port, dbName string, debug bool) *sql.DB
- func ConnectLocal(host, port string) *sql.DB
- func Descr(args ...any)
- func GenerateOrm(tables map[TableName]*TableProp)
- type Adapter
- func (a *Adapter) AlterMissingColumns(tableName TableName, props *TableProp) bool
- func (a *Adapter) CreateMaterializedViews(mvName MaterializedViewName, props *MVProp) bool
- func (a *Adapter) CreateTable(tableName TableName, props *TableProp) bool
- func (a *Adapter) MigrateTables(tables map[TableName]*TableProp)
- func (a *Adapter) UpsertTable(tableName TableName, props *TableProp) bool
- type ChDockerTest
- func (in *ChDockerTest) ConnectCheck(res *dockertest.Resource) (conn *sql.DB, err error)
- func (in *ChDockerTest) ImageLatest(pool *D.DockerTest) *dockertest.RunOptions
- func (in *ChDockerTest) ImageVersion(pool *D.DockerTest, version string) *dockertest.RunOptions
- func (in *ChDockerTest) SetDefaults(img string)
- type DataType
- type Field
- type MVProp
- type MaterializedViewName
- type TableName
- type TableProp
Constants ¶
View Source
const AggregatingMergeTree = `AggregatingMergeTree`
View Source
const Buffer = `Buffer`
View Source
const CodecLz4hc = `CODEC(LZ4HC)`
View Source
const CollapsingMergeTree = `CollapsingMergeTree`
View Source
const Dictionary = `Dictionary`
View Source
const Distributed = `Distributed`
View Source
const EmbeddedRocksDB = `EmbeddedRocksDB`
View Source
const File = `File`
View Source
const GraphiteMergeTree = `GraphiteMergeTree`
View Source
const HDFS = `HDFS`
View Source
const JDBC = `JDBC`
View Source
const Join = `Join`
View Source
const Kafka = `Kafka`
View Source
const Log = `Log`
View Source
const MaterializedView = `MaterializedView`
View Source
const Memory = `Memory`
View Source
const Merge = `Merge`
View Source
const MergeTree = `MergeTree`
View Source
const MongoDB = `MongoDB`
View Source
const MySQL = `MySQL`
View Source
const Null = `Null`
View Source
const ODBC = `ODBC`
View Source
const PostgreSQL = `PostgreSQL`
View Source
const RabbitMQ = `RabbitMQ`
View Source
const ReplacingMergeTree = `ReplacingMergeTree`
View Source
const S3 = `S3`
View Source
const Set = `Set`
View Source
const StripeLog = `StripeLog`
View Source
const SummingMergeTree = `SummingMergeTree`
View Source
const TinyLog = `TinyLog`
View Source
const URL = `URL`
View Source
const VersionedCollapsingMergeTree = `VersionedCollapsingMergeTree`
View Source
const View = `View`
Variables ¶
View Source
var DEBUG = true
View Source
var TypeToConst = map[DataType]string{ DateTime: `Ch.DateTime`, DateTime64: `Ch.DateTime64`, Decimal: `Ch.Decimal`, FixedString: `Ch.FixedString`, Float32: `Ch.Float32`, Float64: `Ch.Float64`, IPv4: `Ch.IPv4`, IPv6: `Ch.IPv6`, Int16: `Ch.Int16`, Int32: `Ch.Int32`, Int64: `Ch.Int64`, Int8: `Ch.Int8`, String: `Ch.String`, UInt16: `Ch.UInt16`, UInt32: `Ch.UInt32`, UInt64: `Ch.UInt64`, }
Functions ¶
func CheckClickhouseTables ¶
func ConnectLocal ¶
func GenerateOrm ¶
Types ¶
type Adapter ¶
func (*Adapter) AlterMissingColumns ¶
func (*Adapter) CreateMaterializedViews ¶ added in v1.3817.2143
func (a *Adapter) CreateMaterializedViews(mvName MaterializedViewName, props *MVProp) bool
func (*Adapter) CreateTable ¶
func (*Adapter) MigrateTables ¶
type ChDockerTest ¶
type ChDockerTest struct { User string Password string Database string Image string Port string // contains filtered or unexported fields }
func (*ChDockerTest) ConnectCheck ¶
func (in *ChDockerTest) ConnectCheck(res *dockertest.Resource) (conn *sql.DB, err error)
func (*ChDockerTest) ImageLatest ¶
func (in *ChDockerTest) ImageLatest(pool *D.DockerTest) *dockertest.RunOptions
func (*ChDockerTest) ImageVersion ¶
func (in *ChDockerTest) ImageVersion(pool *D.DockerTest, version string) *dockertest.RunOptions
ImageVersion https://hub.docker.com/r/clickhouse/clickhouse-server
func (*ChDockerTest) SetDefaults ¶
func (in *ChDockerTest) SetDefaults(img string)
type DataType ¶
type DataType string
SELECT DISTINCT alias_to FROM system.data_type_families ORDER BY alias_to ASC
const ( DateTime DataType = `DateTime` DateTime64 DataType = `DateTime64` Decimal DataType = `Decimal` FixedString DataType = `FixedString` Float32 DataType = `Float32` Float64 DataType = `Float64` IPv4 DataType = `IPv4` IPv6 DataType = `IPv6` Int16 DataType = `Int16` Int32 DataType = `Int32` Int64 DataType = `Int64` Int8 DataType = `Int8` String DataType = `String` UInt16 DataType = `UInt16` UInt32 DataType = `UInt32` UInt64 DataType = `UInt64` UInt8 DataType = `UInt8` )
type MaterializedViewName ¶ added in v1.3817.2143
type MaterializedViewName string
Click to show internal directories.
Click to hide internal directories.