MCPcopy Create free account
hub / github.com/dolthub/doltgresql / pgwireQuoteStringInArray

Function pgwireQuoteStringInArray

postgres/parser/sem/tree/pgwire_encode.go:161–173  ·  view source on GitHub ↗
(in string)

Source from the content-addressed store, hash-verified

159}
160
161func pgwireQuoteStringInArray(in string) bool {
162 if in == "" || arrayQuoteSet.in(in) {
163 return true
164 }
165 if len(in) == 4 &&
166 (in[0] == 'n' || in[0] == 'N') &&
167 (in[1] == 'u' || in[1] == 'U') &&
168 (in[2] == 'l' || in[2] == 'L') &&
169 (in[3] == 'l' || in[3] == 'L') {
170 return true
171 }
172 return false
173}
174
175func pgwireFormatStringInArray(buf *bytes.Buffer, in string) {
176 quote := pgwireQuoteStringInArray(in)

Callers 1

Calls 1

inMethod · 0.80

Tested by

no test coverage detected