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

Method MaxTextResponseByteLength

server/types/type.go:812–820  ·  view source on GitHub ↗

MaxTextResponseByteLength implements the types.ExtendedType interface.

(ctx *sql.Context)

Source from the content-addressed store, hash-verified

810
811// MaxTextResponseByteLength implements the types.ExtendedType interface.
812func (t *DoltgresType) MaxTextResponseByteLength(ctx *sql.Context) uint32 {
813 if t.ID == VarChar.ID {
814 return math.MaxUint32
815 } else if t.TypLength == -1 {
816 return math.MaxUint32
817 } else {
818 return uint32(t.TypLength)
819 }
820}
821
822// ModInFuncName returns the name that would be displayed in pg_type for the `typmodin` field.
823func (t *DoltgresType) ModInFuncName() string {

Callers 3

ComPrepareParsedMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected