MCPcopy Create free account
hub / github.com/cloudquery/cloudquery / exec

Method exec

plugins/destination/duckdb/client/client.go:113–125  ·  view source on GitHub ↗
(ctx context.Context, query string, args ...any)

Source from the content-addressed store, hash-verified

111}
112
113func (c *Client) exec(ctx context.Context, query string, args ...any) error {
114 r, err := c.db.ExecContext(ctx, query, args...)
115 if c.spec.Debug {
116 logEvent := c.logger.Debug().Str("query", query).Any("values", args)
117 if err != nil {
118 logEvent.Err(err).Msg("exec query")
119 } else {
120 rowsAffected, rowsErr := r.RowsAffected()
121 logEvent.Int64("rowsAffected", rowsAffected).Err(rowsErr).Msg("exec query")
122 }
123 }
124 return err
125}
126
127func amendConnectionString(s string) string {
128 if !strings.HasPrefix(s, "md:") {

Callers 11

DeleteStaleMethod · 0.95
recreateTableMethod · 0.95
addColumnMethod · 0.95
createTableIfNotExistMethod · 0.95
ReadMethod · 0.95
upsertMethod · 0.95
deleteByPKMethod · 0.95
copyFromFileMethod · 0.95
WriteTableBatchMethod · 0.95
deleteInsertMethod · 0.95
NewFunction · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected