Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrForecastProcedureResult = werror.InvalidArgument("forecast procedure execution result expected 2 columns", werror.WithID("dbsql.scanner.forecastscan"))
Functions ¶
This section is empty.
Types ¶
type BatchScan ¶
type BatchScan struct {
// contains filtered or unexported fields
}
func MustNewBatchScan ¶
func MustNewBatchScan() *BatchScan
func NewBatchScan ¶
type DBScan ¶
type DBScan struct {
// contains filtered or unexported fields
}
func MustNewDBScan ¶
func MustNewDBScan() *DBScan
type ForecastScan ¶
type ForecastScan struct {
// contains filtered or unexported fields
}
func MustNewForecastScan ¶
func MustNewForecastScan() *ForecastScan
func NewForecastScan ¶
func NewForecastScan() (*ForecastScan, error)
func (*ForecastScan) ScanAll ¶
func (f *ForecastScan) ScanAll(dst interface{}, rows Rows) error
func (*ForecastScan) ScanOne ¶
func (f *ForecastScan) ScanOne(dst interface{}, rows Rows) error
func (*ForecastScan) String ¶
func (f *ForecastScan) String() string
type FrameScan ¶
type FrameScan struct {
// contains filtered or unexported fields
}
func MustNewFrameScan ¶
func MustNewFrameScan() *FrameScan
func NewFrameScan ¶
type Rows ¶
type Rows interface { Close() error Err() error Next() bool Columns() ([]string, error) Types() ([]string, error) Scan(dest ...any) error NextResultSet() bool Values() ([]any, error) }
Rows is an abstract database rows that dbscan can iterate over and get the data from. This interface is used to decouple from any particular database library.
type Scanner ¶
type Scanner interface { String() string ScanOne(dst any, rows Rows) error ScanAll(dst any, rows Rows) error }
Scanner used to configure dbscan API, scan batch results or frame with any values, returning its type.
In case of unique / check / foreign key violations, the driver returns error only after rows.Close call (or while rows.Next returns false). That's why we should parse database error while scanning rows also.
Click to show internal directories.
Click to hide internal directories.