MCPcopy Create free account
hub / github.com/auxten/postgresql-parser / Format

Method Format

pkg/sql/sem/tree/expr.go:610–624  ·  view source on GitHub ↗

Format implements the NodeFormatter interface.

(ctx *FmtCtx)

Source from the content-addressed store, hash-verified

608
609// Format implements the NodeFormatter interface.
610func (node *IsOfTypeExpr) Format(ctx *FmtCtx) {
611 exprFmtWithParen(ctx, node.Expr)
612 ctx.WriteString(" IS")
613 if node.Not {
614 ctx.WriteString(" NOT")
615 }
616 ctx.WriteString(" OF (")
617 for i, t := range node.Types {
618 if i > 0 {
619 ctx.WriteString(", ")
620 }
621 ctx.Buffer.WriteString(t.SQLString())
622 }
623 ctx.WriteByte(')')
624}
625
626// IfErrExpr represents an IFERROR expression.
627type IfErrExpr struct {

Callers

nothing calls this directly

Calls 2

exprFmtWithParenFunction · 0.85
SQLStringMethod · 0.80

Tested by

no test coverage detected