simple-sql-parser-0.8.0: A parser for SQL.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Language.SQL.SimpleSQL.Pretty

Description

These is the pretty printing functions, which produce SQL source from ASTs. The code attempts to format the output in a readable way.

Synopsis

Documentation

prettyQueryExpr :: Dialect -> QueryExpr -> Text Source #

Convert a query expr ast to Text.

prettyScalarExpr :: Dialect -> ScalarExpr -> Text Source #

Convert a value expr ast to Text.

prettyStatement :: Dialect -> Statement -> Text Source #

Convert a statement ast to Text.

prettyStatements :: Dialect -> [Statement] -> Text Source #

Convert a list of statements to Text. A semicolon is inserted after each statement.