sqlfmt

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 8, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FormatSQL

func FormatSQL(sql string) string

func ParseOneSql

func ParseOneSql(sql string) (ast.StmtNode, error)

func RestoreToSqlWithFlag

func RestoreToSqlWithFlag(flag format.RestoreFlags, stmt ast.Node) (string, error)

Types

type FormatVisitor

type FormatVisitor struct{}

func (*FormatVisitor) Enter

func (f *FormatVisitor) Enter(n ast.Node) (node ast.Node, skipChildren bool)

func (*FormatVisitor) Leave

func (f *FormatVisitor) Leave(n ast.Node) (node ast.Node, ok bool)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL