MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / Exec

Method Exec

internal/utils/dbs/stmt.go:48–64  ·  view source on GitHub ↗
(args ...any)

Source from the content-addressed store, hash-verified

46}
47
48func (this *Stmt) Exec(args ...any) (result sql.Result, err error) {
49 // check database status
50 if this.db.BeginUpdating() {
51 defer this.db.EndUpdating()
52 } else {
53 return nil, errDBIsClosed
54 }
55
56 if this.enableStat {
57 defer SharedQueryStatManager.AddQuery(this.query).End()
58 }
59
60 fsutils.WriterLimiter.Ack()
61 result, err = this.rawStmt.Exec(args...)
62 fsutils.WriterLimiter.Release()
63 return
64}
65
66func (this *Stmt) QueryContext(ctx context.Context, args ...any) (*sql.Rows, error) {
67 if this.enableStat {

Callers

nothing calls this directly

Calls 6

BeginUpdatingMethod · 0.80
EndUpdatingMethod · 0.80
AddQueryMethod · 0.80
EndMethod · 0.45
AckMethod · 0.45
ReleaseMethod · 0.45

Tested by

no test coverage detected