Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BulkInsert ¶
type BulkInsert struct {
// contains filtered or unexported fields
}
func NewBulkInsert ¶
func NewBulkInsert(table, colNames, valueQuery string) *BulkInsert
NewBulkInsert
eg 1) INSERT INTO chair(id, name, description, thumbnail, price, height, width, depth, color, features, kind, popularity, stock) VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?)
table -> "chair" columns -> "id, name, description, thumbnail, price, height, width, depth, color, features, kind, popularity, stock" valueQuery -> "(?,?,?,?,?,?,?,?,?,?,?,?,?)"
eg 2) INSERT INTO chair VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?)
table -> "chair" columns -> "" valueQuery -> "(?,?,?,?,?,?,?,?,?,?,?,?,?)"
func NewBulkInsertWithArgNum ¶
func NewBulkInsertWithArgNum(table, colNames, valueQuery string, argNum int) *BulkInsert
func (*BulkInsert) Add ¶
func (b *BulkInsert) Add(args ...any)
func (*BulkInsert) Query ¶
func (b *BulkInsert) Query() (string, []any)
type BulkUpdate ¶
type BulkUpdate struct {
// contains filtered or unexported fields
}
func NewBulkUpdate ¶
func NewBulkUpdate(table, keyCol string, valueCols []string) *BulkUpdate
Click to show internal directories.
Click to hide internal directories.