MCPcopy
hub / github.com/sqlc-dev/sqlc / convertWithClause

Method convertWithClause

internal/engine/dolphin/convert.go:631–645  ·  view source on GitHub ↗
(n *pcast.WithClause)

Source from the content-addressed store, hash-verified

629}
630
631func (c *cc) convertWithClause(n *pcast.WithClause) *ast.WithClause {
632 if n == nil {
633 return nil
634 }
635 list := &ast.List{}
636 for _, n := range n.CTEs {
637 list.Items = append(list.Items, c.convertCommonTableExpression(n))
638 }
639
640 return &ast.WithClause{
641 Ctes: list,
642 Recursive: n.IsRecursive,
643 Location: n.OriginTextPosition(),
644 }
645}
646
647func (c *cc) convertUpdateStmt(n *pcast.UpdateStmt) *ast.UpdateStmt {
648 rels := c.convertTableRefsClause(n.TableRefs)

Callers 4

convertDeleteStmtMethod · 0.95
convertSelectStmtMethod · 0.95
convertUpdateStmtMethod · 0.95

Calls 1

Tested by

no test coverage detected