MCPcopy
hub / github.com/jackc/pgx / SendExecute

Method SendExecute

pgproto3/frontend.go:224–240  ·  view source on GitHub ↗

SendExecute sends an Execute message to the backend (i.e. the server). The message is buffered until Flush is called. Any error encountered will be returned from Flush.

(msg *Execute)

Source from the content-addressed store, hash-verified

222// SendExecute sends an Execute message to the backend (i.e. the server). The message is buffered until Flush is called.
223// Any error encountered will be returned from Flush.
224func (f *Frontend) SendExecute(msg *Execute) {
225 if f.encodeError != nil {
226 return
227 }
228
229 prevLen := len(f.wbuf)
230 newBuf, err := msg.Encode(f.wbuf)
231 if err != nil {
232 f.encodeError = err
233 return
234 }
235 f.wbuf = newBuf
236
237 if f.tracer != nil {
238 f.tracer.traceExecute('F', int32(len(f.wbuf)-prevLen), msg)
239 }
240}
241
242// SendSync sends a Sync message to the backend (i.e. the server). The message is buffered until Flush is called. Any
243// error encountered will be returned from Flush.

Callers 4

execExtendedSuffixMethod · 0.80
SendQueryParamsMethod · 0.80
SendQueryPreparedMethod · 0.80
SendQueryStatementMethod · 0.80

Calls 2

traceExecuteMethod · 0.80
EncodeMethod · 0.65

Tested by

no test coverage detected