!6      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./012345Safe6789:;<=Safe2"#simple-sql-parser]Used to set the dialect used for parsing and pretty printing, very unfinished at the moment.simple-sql-parseransi sql 2011 dialectsimple-sql-parser mysql dialectsimple-sql-parserpostgresql dialectsimple-sql-parseroracle dialectsimple-sql-parsermicrosoft sql server dialect>?@ABCSafe'\ simple-sql-parserType to represent parse errors. simple-sql-parsercontains the error message simple-sql-parserfilename location for the error simple-sql-parser4line number and column number location for the errorsimple-sql-parserDformatted error with the position, error message and source context DSafePG,simple-sql-parserRepresents a lexed tokensimple-sql-parser2A symbol (in ansi dialect) is one of the following!multi char symbols <> <= >= != ||single char symbols: * + -   ^ / % ~ & | ? ( ) [ ] , ; ( )simple-sql-parserThis is an identifier or keyword. The first field is the quotes used, or nothing if no quotes were used. The quotes can be " or u& or something dialect specific like []simple-sql-parsercThis is a prefixed variable symbol, such as :var, @var or #var (only :var is used in ansi dialect)simple-sql-parser+This is a positional arg identifier e.g. $1simple-sql-parserThis is a string literal. The first two fields are the -- start and end quotes, which are usually both ', but can be the character set (one of nNbBxX, or u&, U&), or a dialect specific string quoting (such as $$ in postgres)simple-sql-parserNA number literal (integral or otherwise), stored in original format unchangedsimple-sql-parser1Whitespace, one or more of space, tab or newline.simple-sql-parserA commented line using --, contains every character starting with the '--' and including the terminating newline character if there is one - this will be missing if the last line in the source is a line comment with no trailing newlinesimple-sql-parser=A block comment, /* stuff */, includes the comment delimiterssimple-sql-parservPretty printing, if you lex a bunch of tokens, then pretty print them, should should get back exactly the same stringsimple-sql-parser!Lex some SQL to a list of tokens.Esimple-sql-parserparser for a sql tokensimple-sql-parserUtility function to tell you if a list of tokens will pretty print then lex back to the same set of tokens. Used internally, might be useful for generating SQL via lexical tokens.simple-sql-parserdialect of SQL to usesimple-sql-parser!filename to use in error messagessimple-sql-parser\line number and column number of the first character in the source to use in error messagessimple-sql-parserthe SQL source to lex  Safe2Osimple-sql-parser]Comment. Useful when generating SQL code programmatically. The parser doesn't produce these.simple-sql-parserThe join condition.simple-sql-parseron exprsimple-sql-parserusing (column list)simple-sql-parserThe type of a join.simple-sql-parserRepresents an alias for a table valued expression, used in with queries and in from alias, e.g. select a from t u, select a from t u(b), with a(c) as select 1, select * from a.simple-sql-parser;Represents a entry in the csv of tables in the from clause.simple-sql-parserfrom t / from s.tsimple-sql-parser3from a join b, the bool is true if natural was usedsimple-sql-parserfrom (a)simple-sql-parserfrom a as b(c,d)simple-sql-parserfrom (query expr)simple-sql-parserfrom function(args)simple-sql-parserfrom lateral tsimple-sql-parser.ODBC {oj t1 left outer join t2 on expr} syntaxsimple-sql-parser(Represents an item in a group by clause.simple-sql-parser/Corresponding, an option for the set operators.simple-sql-parserQuery expression set operators.simple-sql-parser'The direction for a column in order by.simple-sql-parserRepresents the Distinct or All keywords, which can be used before a select list, in an aggregate/window function application, or in a query expression set operator.simple-sql-parser,Represents a query expression, which can be:a regular select;*a set operator (union, except, intersect);!a common table expression (with);2a table value constructor (values (1,2),(3,4)); oran explicit table (table t).simple-sql-parser&the expressions and the column aliasessimple-sql-parser%the type of an odbc literal (e.g. {d  '2000-01-01'4}), correpsonding to the letter after the opening {simple-sql-parser&represents the start or end of a framesimple-sql-parser@Represents whether a window frame clause is over rows or ranges.simple-sql-parserRepresents the frame clause of a window this can be [range | rows] frame_start or [range | rows] between frame_start and frame_endsimple-sql-parser?Represents 'nulls first' or 'nulls last' in an order by clause.simple-sql-parser)Represents one field in an order by list. simple-sql-parser"A subquery in a scalar expression. simple-sql-parserexists (query expr) simple-sql-parserunique (query expr) simple-sql-parsera scalar subquery simple-sql-parserNUsed for 'expr in (scalar expression list)', and 'expr in (subquery)' syntax.simple-sql-parser&Represents a type name, used in casts.)simple-sql-parserJRepresents an identifier name, which can be quoted or unquoted. examples:test -> Name Nothing "test"$"test" -> Name (Just """,""") "test" something$ -> Name (Just ("`","`") "something"![ms] -> Name (Just ("[","]") "ms"+simple-sql-parserRepresents a value expression. This is used for the expressions in select lists. It is also used for expressions in where, group by, having, order by and so on.,simple-sql-parserEa numeric literal optional decimal point, e+- integral exponent, e.g1010..110.11e512.34e-6-simple-sql-parser3string literal, with the start and end quote e.g. test -> StringLit "'" "'" "test".simple-sql-parserPtext of interval literal, units of interval precision, e.g. interval 3 days (3)/simple-sql-parser!prefix 'typed literal', e.g. int '42'0simple-sql-parser'identifier with parts separated by dots1simple-sql-parser#star, as in select *, t.*, count(*)2simple-sql-parser'Represents a ? in a parameterized query3simple-sql-parser.Represents an e.g. $1 in a parameterized query4simple-sql-parserhrepresents a host parameter, e.g. :a. The Maybe String is for the indicator, e.g. :var indicator :nl5simple-sql-parserInfix binary operators. This is used for symbol operators (a + b), keyword operators (a and b) and multiple keyword operators (a is similar to b)6simple-sql-parsermPrefix unary operators. This is used for symbol operators, keyword operators and multiple keyword operators.7simple-sql-parsernPostfix unary operators. This is used for symbol operators, keyword operators and multiple keyword operators.8simple-sql-parserrUsed for ternary, mixfix and other non orthodox operators. Currently used for row constructors, and for between.9simple-sql-parser[function application (anything that looks like c style function application syntactically):simple-sql-parseraaggregate application, which adds distinct or all, and order by, to regular function application;simple-sql-parseraggregates with within group<simple-sql-parserwindow application, which adds over (partition by a order by b) to regular function application. Explicit frames are not currently supported=simple-sql-parserUsed for the operators which look like functions except the arguments are separated by keywords instead of commas. The maybe is for the first unnamed argument if it is present, and the list is for the keyword argument pairs.>simple-sql-parsercast(a as typename)?simple-sql-parser(case expression. both flavours supportedAsimple-sql-parserbin list literal and in subquery, if the bool is false it means not in was used ('a not in (1,2)')Bsimple-sql-parser!exists, all, any, some subqueriesEsimple-sql-parserrepresents an array access expression, or an array ctor e.g. a[3]. The first scalarExpr is the array, the second is the subscripts/ctor argsFsimple-sql-parser`this is used for the query expression version of array constructors, e.g. array(select * from t)Msimple-sql-parseran odbc literal e.g. {d  '2000-01-01'}Nsimple-sql-parser0an odbc function call e.g. {fn CHARACTER_LENGTH(test)}Osimple-sql-parserif + or - usedPsimple-sql-parser literal textSsimple-sql-parseraggregate function nameTsimple-sql-parserdistinctUsimple-sql-parserargsVsimple-sql-parserorder byWsimple-sql-parserfilterXsimple-sql-parser within groupYsimple-sql-parserwindow function nameZsimple-sql-parserargs[simple-sql-parser partition by\simple-sql-parserorder by]simple-sql-parser frame clause^simple-sql-parser test value_simple-sql-parser when branches`simple-sql-parser else valueasimple-sql-parserHelper/ 'default'd value for query exprs to make creating query expr values a little easier. It is defined like this: |makeSelect :: QueryExpr makeSelect = Select {qeSetQuantifier = SQDefault ,qeSelectList = [] ,qeFrom = [] ,qeWhere = Nothing ,qeGroupBy = [] ,qeHaving = Nothing ,qeOrderBy = [] ,qeOffset = Nothing ,qeFetchFirst = Nothing}J !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+DE93,-./01245678:;<=>?@ABCFGHIJKLMNOPQRSTUVWXYZ[\]^_`aJ+DE93,-./01245678:;<=>?@ABCFGHIJKLMNOPQRSTUVWXYZ[\]^_`)* !"#$%&'(     a}~{|TUVWQRSFGHIJKLMNOPyzstuvwxnopqrijklmbcdefghXYZ[\]^_`aBCDE=>?@A:;<789+,-./0!"#$%&'()*456123 Safe.simple-sql-parser,Convert a query expr ast to concrete syntax./simple-sql-parser,Convert a value expr ast to concrete syntax.0simple-sql-parser+Convert a statement ast to concrete syntax.1simple-sql-parser_Convert a list of statements to concrete syntax. A semicolon is inserted after each statement../01./01SafePұ2simple-sql-parser1Parses a query expr, trailing semicolon optional.3simple-sql-parser0Parses a statement, trailing semicolon optional.4simple-sql-parser]Parses a list of statements, with semi colons between them. The final semicolon is optional.5simple-sql-parserParses a scalar expression.2simple-sql-parserdialect of SQL to usesimple-sql-parser!filename to use in error messagessimple-sql-parser\line number and column number of the first character in the source to use in error messagessimple-sql-parserthe SQL source to parse3simple-sql-parserdialect of SQL to usesimple-sql-parser!filename to use in error messagessimple-sql-parser\line number and column number of the first character in the source to use in error messagessimple-sql-parserthe SQL source to parse4simple-sql-parserdialect of SQL to usesimple-sql-parser!filename to use in error messagessimple-sql-parser\line number and column number of the first character in the source to use in error messagessimple-sql-parserthe SQL source to parse5simple-sql-parserdialect of SQL to usesimple-sql-parser!filename to use in error messagessimple-sql-parser\line number and column number of the first character in the source to use in error messagessimple-sql-parserthe SQL source to parse 2345 2534 F      !"#$%&'()*+,-./012345667889:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{{||}~      !"#$$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?.simple-sql-parser-0.5.0-FSl8HO7daEQ2TW4vUzw6PsLanguage.SQL.SimpleSQL.LexLanguage.SQL.SimpleSQL.SyntaxLanguage.SQL.SimpleSQL.PrettyLanguage.SQL.SimpleSQL.Parse"Language.SQL.SimpleSQL.CombinatorsLanguage.SQL.SimpleSQL.DialectLanguage.SQL.SimpleSQL.ErrorsDialectdiSyntaxFlavour allowOdbcansi2011mysqlpostgresoracle sqlserver ParseError peErrorString peFilename pePositionpeFormattedErrorTokenSymbol IdentifierPrefixedVariable PositionalArg SqlString SqlNumber Whitespace LineComment BlockComment prettyToken prettyTokenslexSQLtokenListWillPrintAndLex $fEqToken $fShowTokenCommentPrivilegeActionPrivAll PrivSelect PrivDelete PrivInsert PrivUpdatePrivReferences PrivUsage PrivTrigger PrivExecutePrivilegeObject PrivTable PrivDomainPrivType PrivSequence PrivFunctionGrantOptionForNoGrantOptionForAdminOptionForNoAdminOptionFor GrantOptionWithGrantOptionWithoutGrantOption AdminOptionWithAdminOptionWithoutAdminOptionAlterDomainAction ADSetDefault ADDropDefaultADAddConstraintADDropConstraint CheckOptionDefaultCheckOptionCascadedCheckOptionLocalCheckOptionSequenceGeneratorOption SGODataType SGOStartWith SGORestartSGOIncrementBy SGOMaxValue SGONoMaxValue SGOMinValue SGONoMinValueSGOCycle SGONoCycle IdentityWhenGeneratedAlwaysGeneratedByDefault DefaultClauseIdentityColumnSpecGenerationClauseAlterTableAction AddColumnDefAlterColumnSetDefaultAlterColumnDropDefaultAlterColumnSetNotNullAlterColumnDropNotNullAlterColumnSetDataType DropColumnAddTableConstraintDefDropTableConstraintDefReferentialActionDefaultReferentialAction RefCascade RefSetNull RefSetDefault RefRestrict RefNoActionReferenceMatchDefaultReferenceMatch MatchFull MatchPartial MatchSimpleTableConstraintTableUniqueConstraintTablePrimaryKeyConstraintTableReferencesConstraintTableCheckConstraint ColConstraintColNotNullConstraintColUniqueConstraintColPrimaryKeyConstraintColReferencesConstraintColCheckConstraintColConstraintDef ColumnDef TableElementTableColumnDefTableConstraintDef SetClauseSet SetMultiple InsertSource InsertQueryDefaultInsertValuesIdentityRestartContinueIdentityRestartIdentityDefaultIdentityRestart DropBehaviourRestrictCascadeDefaultDropBehaviour Statement CreateSchema DropSchema CreateTable AlterTable DropTable CreateViewDropView CreateDomain AlterDomain DropDomainCreateAssertion DropAssertionCreateSequence AlterSequence DropSequenceSelectStatementDeleteTruncateInsertUpdateGrantPrivilege GrantRole CreateRoleDropRoleRevokePrivilege RevokeRoleStartTransaction SavepointReleaseSavepointCommitRollbackStatementComment JoinConditionJoinOn JoinUsingJoinTypeJInnerJLeftJRightJFullJCrossAliasTableRefTRSimpleTRJoinTRParensTRAlias TRQueryExpr TRFunction TRLateralTROdbc GroupingExprGroupingParensCubeRollup GroupingSets SimpleGroup Corresponding RespectivelySetOperatorNameUnionExcept Intersect Direction DirDefaultAscDesc SetQuantifier SQDefaultDistinctAll QueryExprSelectQueryExprSetOpWithValuesTable QECommentqeSetQuantifier qeSelectListqeFromqeWhere qeGroupByqeHaving qeOrderByqeOffset qeFetchFirstqe0qeCombOpqeCorrespondingqe1qeWithRecursiveqeViewsqeQueryExpressionOdbcLiteralTypeOLDateOLTime OLTimestampFramePosUnboundedPreceding PrecedingCurrent FollowingUnboundedFollowing FrameRows FrameRangeFrame FrameFrom FrameBetween NullsOrderNullsOrderDefault NullsFirst NullsLastSortSpecCompPredQuantifierCPAnyCPSomeCPAllSubQueryExprTypeSqExistsSqUniqueSqSq InPredValueInList InQueryExpr PrecUnitsPrecCharacters PrecOctetsPrecMultiplierPrecKPrecMPrecGPrecTPrecPSignPlusMinusIntervalTypeFieldItfTypeName PrecTypeNamePrecScaleTypeNamePrecLengthTypeName CharTypeName TimeTypeName RowTypeNameIntervalTypeName ArrayTypeNameMultisetTypeNameName ScalarExprNumLit StringLit IntervalLitTypedLitIdenStar Parameter HostParameterBinOpPrefixOp PostfixOp SpecialOpApp AggregateAppAggregateAppGroup WindowApp SpecialOpKCastCaseParensIn SubQueryExprQuantifiedComparisonMatchArray ArrayCtorCollate MultisetBinOp MultisetCtorMultisetQueryCtor NextValueFor VEComment OdbcLiteralOdbcFuncilSign ilLiteralilFromilToaggName aggDistinctaggArgs aggOrderBy aggFilteraggGroupwnNamewnArgs wnPartition wnOrderBywnFramecaseTest caseWhenscaseElse makeSelect$fEqName $fShowName $fReadName $fDataName$fEqIntervalTypeField$fShowIntervalTypeField$fReadIntervalTypeField$fDataIntervalTypeField$fEqSign $fShowSign $fReadSign $fDataSign$fEqPrecMultiplier$fShowPrecMultiplier$fReadPrecMultiplier$fDataPrecMultiplier $fEqPrecUnits$fShowPrecUnits$fReadPrecUnits$fDataPrecUnits $fEqTypeName$fShowTypeName$fReadTypeName$fDataTypeName$fEqSubQueryExprType$fShowSubQueryExprType$fReadSubQueryExprType$fDataSubQueryExprType$fEqCompPredQuantifier$fShowCompPredQuantifier$fReadCompPredQuantifier$fDataCompPredQuantifier$fEqNullsOrder$fShowNullsOrder$fReadNullsOrder$fDataNullsOrder $fEqFrameRows$fShowFrameRows$fReadFrameRows$fDataFrameRows$fEqOdbcLiteralType$fShowOdbcLiteralType$fReadOdbcLiteralType$fDataOdbcLiteralType$fEqSetQuantifier$fShowSetQuantifier$fReadSetQuantifier$fDataSetQuantifier $fEqDirection$fShowDirection$fReadDirection$fDataDirection$fEqSetOperatorName$fShowSetOperatorName$fReadSetOperatorName$fDataSetOperatorName$fEqCorresponding$fShowCorresponding$fReadCorresponding$fDataCorresponding $fEqAlias $fShowAlias $fReadAlias $fDataAlias $fEqJoinType$fShowJoinType$fReadJoinType$fDataJoinType$fEqDropBehaviour$fShowDropBehaviour$fReadDropBehaviour$fDataDropBehaviour$fEqIdentityRestart$fShowIdentityRestart$fReadIdentityRestart$fDataIdentityRestart$fEqReferenceMatch$fShowReferenceMatch$fReadReferenceMatch$fDataReferenceMatch$fEqReferentialAction$fShowReferentialAction$fReadReferentialAction$fDataReferentialAction$fEqIdentityWhen$fShowIdentityWhen$fReadIdentityWhen$fDataIdentityWhen$fEqSequenceGeneratorOption$fShowSequenceGeneratorOption$fReadSequenceGeneratorOption$fDataSequenceGeneratorOption$fEqCheckOption$fShowCheckOption$fReadCheckOption$fDataCheckOption$fEqAdminOption$fShowAdminOption$fReadAdminOption$fDataAdminOption$fEqGrantOption$fShowGrantOption$fReadGrantOption$fDataGrantOption$fEqAdminOptionFor$fShowAdminOptionFor$fReadAdminOptionFor$fDataAdminOptionFor$fEqGrantOptionFor$fShowGrantOptionFor$fReadGrantOptionFor$fDataGrantOptionFor$fEqPrivilegeObject$fShowPrivilegeObject$fReadPrivilegeObject$fDataPrivilegeObject$fEqPrivilegeAction$fShowPrivilegeAction$fReadPrivilegeAction$fDataPrivilegeAction $fEqComment $fShowComment $fReadComment $fDataComment$fEqScalarExpr$fShowScalarExpr$fReadScalarExpr$fDataScalarExpr $fEqQueryExpr$fShowQueryExpr$fReadQueryExpr$fDataQueryExpr $fEqTableRef$fShowTableRef$fReadTableRef$fDataTableRef$fEqJoinCondition$fShowJoinCondition$fReadJoinCondition$fDataJoinCondition$fEqGroupingExpr$fShowGroupingExpr$fReadGroupingExpr$fDataGroupingExpr $fEqSortSpec$fShowSortSpec$fReadSortSpec$fDataSortSpec $fEqFrame $fShowFrame $fReadFrame $fDataFrame $fEqFramePos$fShowFramePos$fReadFramePos$fDataFramePos$fEqInPredValue$fShowInPredValue$fReadInPredValue$fDataInPredValue$fEqAlterDomainAction$fShowAlterDomainAction$fReadAlterDomainAction$fDataAlterDomainAction$fEqDefaultClause$fShowDefaultClause$fReadDefaultClause$fDataDefaultClause$fEqTableConstraint$fShowTableConstraint$fReadTableConstraint$fDataTableConstraint$fEqColConstraint$fShowColConstraint$fReadColConstraint$fDataColConstraint$fEqColConstraintDef$fShowColConstraintDef$fReadColConstraintDef$fDataColConstraintDef $fEqColumnDef$fShowColumnDef$fReadColumnDef$fDataColumnDef$fEqAlterTableAction$fShowAlterTableAction$fReadAlterTableAction$fDataAlterTableAction$fEqTableElement$fShowTableElement$fReadTableElement$fDataTableElement $fEqSetClause$fShowSetClause$fReadSetClause$fDataSetClause$fEqInsertSource$fShowInsertSource$fReadInsertSource$fDataInsertSource $fEqStatement$fShowStatement$fReadStatement$fDataStatementprettyQueryExprprettyScalarExprprettyStatementprettyStatementsparseQueryExprparseStatementparseStatementsparseScalarExpr optionSuffix<$$><$$$><$$$$><$$$$$> SyntaxFlavourANSI2011MySQLPostgresOracle SQLServerconvParseErrorsqlToken