ClickhouseClient overview
Added in v1.0.0
Table of contents
compiler
makeCompiler
Signature
export declare const makeCompiler: (transform?: (_: string) => string) => any
Added in v1.0.0
constructors
ClickhouseClientConfig (interface)
Signature
export interface ClickhouseClientConfig extends Clickhouse.ClickHouseClientConfigOptions {
readonly spanAttributes?: Record<string, unknown> | undefined
readonly transformResultNames?: ((str: string) => string) | undefined
readonly transformQueryNames?: ((str: string) => string) | undefined
}
Added in v1.0.0
make
Signature
export declare const make: (
options: ClickhouseClientConfig
) => Effect.Effect<ClickhouseClient, SqlError, Scope.Scope | Reactivity.Reactivity>
Added in v1.0.0
custom types
ClickhouseCustom (type alias)
Signature
export type ClickhouseCustom = ClickhouseParam
Added in v1.0.0
fiber refs
currentClickhouseSettings
Signature
export declare const currentClickhouseSettings: FiberRef.FiberRef<
Partial<ClickHouseServerSettings> &
Partial<ClickHouseHTTPSettings> &
Record<string, string | number | boolean | Clickhouse.SettingsMap | undefined>
>
Added in v1.0.0
currentClientMethod
Signature
export declare const currentClientMethod: FiberRef.FiberRef<"query" | "command" | "insert">
Added in v1.0.0
currentQueryId
Signature
export declare const currentQueryId: FiberRef.FiberRef<string | undefined>
Added in v1.0.0
layers
layer
Signature
export declare const layer: (
config: ClickhouseClientConfig
) => Layer.Layer<ClickhouseClient | Client.SqlClient, ConfigError | SqlError>
Added in v1.0.0
layerConfig
Signature
export declare const layerConfig: (
config: Config.Config.Wrap<ClickhouseClientConfig>
) => Layer.Layer<ClickhouseClient | Client.SqlClient, ConfigError | SqlError>
Added in v1.0.0
models
ClickhouseClient (interface)
Signature
export interface ClickhouseClient extends Client.SqlClient {
readonly [TypeId]: TypeId
readonly config: ClickhouseClientConfig
readonly param: (dataType: string, value: Statement.Primitive) => Statement.Fragment
readonly asCommand: <A, E, R>(effect: Effect.Effect<A, E, R>) => Effect.Effect<A, E, R>
readonly insertQuery: <T = unknown>(options: {
readonly table: string
readonly values: Clickhouse.InsertValues<Readable, T>
readonly format?: Clickhouse.DataFormat
}) => Effect.Effect<Clickhouse.InsertResult, SqlError>
readonly withQueryId: {
(queryId: string): <A, E, R>(effect: Effect.Effect<A, E, R>) => Effect.Effect<A, E, R>
<A, E, R>(effect: Effect.Effect<A, E, R>, queryId: string): Effect.Effect<A, E, R>
}
readonly withClickhouseSettings: {
(
settings: NonNullable<Clickhouse.BaseQueryParams["clickhouse_settings"]>
): <A, E, R>(effect: Effect.Effect<A, E, R>) => Effect.Effect<A, E, R>
<A, E, R>(
effect: Effect.Effect<A, E, R>,
settings: NonNullable<Clickhouse.BaseQueryParams["clickhouse_settings"]>
): Effect.Effect<A, E, R>
}
}
Added in v1.0.0
tags
ClickhouseClient
Signature
export declare const ClickhouseClient: any
Added in v1.0.0
type ids
TypeId
Signature
export declare const TypeId: typeof TypeId
Added in v1.0.0
TypeId (type alias)
Signature
export type TypeId = typeof TypeId
Added in v1.0.0