Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidDSNUnescaped = &errors.TaosError{Code: 0xffff, ErrStr: "invalid DSN: did you forget to escape a param value?"} ErrInvalidDSNAddr = &errors.TaosError{Code: 0xffff, ErrStr: "invalid DSN: network address not terminated (missing closing brace)"} ErrInvalidDSNPort = &errors.TaosError{Code: 0xffff, ErrStr: "invalid DSN: network port is not a valid number"} ErrInvalidDSNNoSlash = &errors.TaosError{Code: 0xffff, ErrStr: "invalid DSN: missing the slash separating the database name"} )
Functions ¶
Types ¶
type Config ¶ added in v3.6.0
type Config struct { User string // Username Passwd string // Password (requires User) Net string // Network type Addr string // Network address (requires Net) Port int DbName string // Database name Params map[string]string // Connection parameters InterpolateParams bool // Interpolate placeholders into query string DisableCompression bool ReadBufferSize int Token string // cloud platform Token SkipVerify bool }
Config is a configuration parsed from a DSN string. If a new Config is created instead of being parsed from a DSN string, the NewConfig function should be used, which sets default values.
type TDengineDriver ¶ added in v3.0.1
type TDengineDriver struct{}
TDengineDriver is exported to make the driver directly accessible. In general the driver is used via the database/sql package.
func (TDengineDriver) Open ¶ added in v3.0.1
func (d TDengineDriver) Open(dsn string) (driver.Conn, error)
Open new Connection. the DSN string is formatted
func (TDengineDriver) OpenConnector ¶ added in v3.6.0
func (d TDengineDriver) OpenConnector(dsn string) (driver.Connector, error)
OpenConnector implements driver.DriverContext.
Click to show internal directories.
Click to hide internal directories.