sql

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 1, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CollectionSql

type CollectionSql struct {
	DBSql
	CollectionName string
}

func (CollectionSql) Create

func (s CollectionSql) Create() string

func (CollectionSql) DeleteStmt

func (s CollectionSql) DeleteStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (CollectionSql) Drop

func (s CollectionSql) Drop() string

func (CollectionSql) FindIdStmt

func (s CollectionSql) FindIdStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (CollectionSql) Index

func (s CollectionSql) Index(indexName string) IndexSql

func (CollectionSql) InsertStmt

func (s CollectionSql) InsertStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (CollectionSql) Rename

func (s CollectionSql) Rename(newName string) string

func (CollectionSql) TableName

func (s CollectionSql) TableName() string

func (CollectionSql) UpdateStmt

func (s CollectionSql) UpdateStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (CollectionSql) With2Coll

func (s CollectionSql) With2Coll(sql, name string) string

func (CollectionSql) WithColl

func (s CollectionSql) WithColl(sql string) string

type DBSql

type DBSql struct {
	Namespace string
}

func (DBSql) Collection

func (s DBSql) Collection(name string) CollectionSql

func (DBSql) CountCollections

func (s DBSql) CountCollections() string

func (DBSql) CountIndexes

func (s DBSql) CountIndexes() string

func (DBSql) FindCollection

func (s DBSql) FindCollection() string

func (DBSql) FindCollections

func (s DBSql) FindCollections() string

func (DBSql) FindIndexes

func (s DBSql) FindIndexes() string

func (DBSql) InitDB

func (s DBSql) InitDB() string

func (DBSql) Prepare

func (s DBSql) Prepare(ctx context.Context, c conn.Conn, query string) (conn.Stmt, error)

func (DBSql) RegisterCollectionStmt

func (s DBSql) RegisterCollectionStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (DBSql) RegisterIndexStmt

func (s DBSql) RegisterIndexStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (DBSql) RemoveCollectionStmt

func (s DBSql) RemoveCollectionStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (DBSql) RemoveIndexStmt

func (s DBSql) RemoveIndexStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (DBSql) RenameCollectionIndexStmt

func (s DBSql) RenameCollectionIndexStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (DBSql) RenameCollectionStmt

func (s DBSql) RenameCollectionStmt(ctx context.Context, c conn.Conn) (conn.Stmt, error)

func (DBSql) StatsDataSize

func (s DBSql) StatsDataSize() string

func (DBSql) StatsTotalSize

func (s DBSql) StatsTotalSize() string

func (DBSql) WithNS

func (s DBSql) WithNS(sql string) string

type IndexSql

type IndexSql struct {
	CollectionSql
	IndexName string
}

func (IndexSql) Create

func (s IndexSql) Create(unique bool, fieldsIsDesc []bool) string

func (IndexSql) DeleteStmt

func (s IndexSql) DeleteStmt(ctx context.Context, cn conn.Conn, numFields int) (conn.Stmt, error)

func (IndexSql) Drop

func (s IndexSql) Drop() string

func (IndexSql) InsertStmt

func (s IndexSql) InsertStmt(ctx context.Context, cn conn.Conn, numFields int) (conn.Stmt, error)

func (IndexSql) RenameColl

func (s IndexSql) RenameColl(newCollName string) string

func (IndexSql) TableName

func (s IndexSql) TableName() string

func (IndexSql) WithIndex

func (s IndexSql) WithIndex(sql string) string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL