beam-core-0.9.2.1: Type-safe, feature-complete SQL query and manipulation interface for Haskell
Safe HaskellNone
LanguageHaskell2010

Database.Beam.Backend.SQL.AST

Description

This module implements an AST type for SQL92. It allows us to realize the call structure of the builders defined in Database.Beam.Backend.SQL.SQL92

Documentation

data Command Source #

data SelectTable Source #

Instances

Instances details
Eq SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

Show SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql92SelectTableSyntax SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92SelectTableSelectSyntax SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92SelectTableExpressionSyntax SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92SelectTableProjectionSyntax SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92SelectTableFromSyntax SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92SelectTableGroupingSyntax SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92SelectTableSetQuantifierSyntax SelectTable Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

data DataType Source #

Instances

Instances details
Eq DataType Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

Show DataType Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql92DataTypeSyntax DataType Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql99DataTypeSyntax DataType Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql2008BigIntDataTypeSyntax DataType Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

data Expression Source #

Constructors

ExpressionValue Value 
ExpressionDefault 
ExpressionRow [Expression] 
ExpressionIn Expression [Expression] 
ExpressionIsNull Expression 
ExpressionIsNotNull Expression 
ExpressionIsTrue Expression 
ExpressionIsNotTrue Expression 
ExpressionIsFalse Expression 
ExpressionIsNotFalse Expression 
ExpressionIsUnknown Expression 
ExpressionIsNotUnknown Expression 
ExpressionCase [(Expression, Expression)] Expression 
ExpressionCoalesce [Expression] 
ExpressionNullIf Expression Expression 
ExpressionFieldName FieldName 
ExpressionBetween Expression Expression Expression 
ExpressionBinOp Text Expression Expression 
ExpressionCompOp Text (Maybe ComparatorQuantifier) Expression Expression 
ExpressionUnOp Text Expression 
ExpressionPosition Expression Expression 
ExpressionCast Expression DataType 
ExpressionExtract ExtractField Expression 
ExpressionCharLength Expression 
ExpressionOctetLength Expression 
ExpressionBitLength Expression 
ExpressionAbs Expression 
ExpressionLower Expression 
ExpressionUpper Expression 
ExpressionTrim Expression 
ExpressionNamedFunction Text 
ExpressionFunctionCall Expression [Expression] 
ExpressionInstanceField Expression Text 
ExpressionRefField Expression Text 
ExpressionCountAll 
ExpressionAgg Text (Maybe SetQuantifier) [Expression] 
ExpressionBuiltinFunction Text [Expression] 
ExpressionSubquery Select 
ExpressionUnique Select 
ExpressionDistinct Select 
ExpressionExists Select 
ExpressionOver Expression WindowFrame 
ExpressionCurrentTimestamp 

Instances

Instances details
Eq Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

Show Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql92AggregationExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql92ExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

Methods

valueE :: Sql92ExpressionValueSyntax Expression -> Expression Source #

rowE :: [Expression] -> Expression Source #

quantifierListE :: [Expression] -> Expression Source #

coalesceE :: [Expression] -> Expression Source #

caseE :: [(Expression, Expression)] -> Expression -> Expression Source #

fieldE :: Sql92ExpressionFieldNameSyntax Expression -> Expression Source #

betweenE :: Expression -> Expression -> Expression -> Expression Source #

andE :: Expression -> Expression -> Expression Source #

orE :: Expression -> Expression -> Expression Source #

addE :: Expression -> Expression -> Expression Source #

subE :: Expression -> Expression -> Expression Source #

mulE :: Expression -> Expression -> Expression Source #

divE :: Expression -> Expression -> Expression Source #

likeE :: Expression -> Expression -> Expression Source #

modE :: Expression -> Expression -> Expression Source #

overlapsE :: Expression -> Expression -> Expression Source #

nullIfE :: Expression -> Expression -> Expression Source #

positionE :: Expression -> Expression -> Expression Source #

eqE :: Maybe (Sql92ExpressionQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

neqE :: Maybe (Sql92ExpressionQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

ltE :: Maybe (Sql92ExpressionQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

gtE :: Maybe (Sql92ExpressionQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

leE :: Maybe (Sql92ExpressionQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

geE :: Maybe (Sql92ExpressionQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

eqMaybeE :: Expression -> Expression -> Expression -> Expression Source #

neqMaybeE :: Expression -> Expression -> Expression -> Expression Source #

castE :: Expression -> Sql92ExpressionCastTargetSyntax Expression -> Expression Source #

notE :: Expression -> Expression Source #

negateE :: Expression -> Expression Source #

isNullE :: Expression -> Expression Source #

isNotNullE :: Expression -> Expression Source #

isTrueE :: Expression -> Expression Source #

isNotTrueE :: Expression -> Expression Source #

isFalseE :: Expression -> Expression Source #

isNotFalseE :: Expression -> Expression Source #

isUnknownE :: Expression -> Expression Source #

isNotUnknownE :: Expression -> Expression Source #

charLengthE :: Expression -> Expression Source #

octetLengthE :: Expression -> Expression Source #

bitLengthE :: Expression -> Expression Source #

lowerE :: Expression -> Expression Source #

upperE :: Expression -> Expression Source #

trimE :: Expression -> Expression Source #

absE :: Expression -> Expression Source #

extractE :: Sql92ExpressionExtractFieldSyntax Expression -> Expression -> Expression Source #

existsE :: Sql92ExpressionSelectSyntax Expression -> Expression Source #

uniqueE :: Sql92ExpressionSelectSyntax Expression -> Expression Source #

subqueryE :: Sql92ExpressionSelectSyntax Expression -> Expression Source #

currentTimestampE :: Expression Source #

defaultE :: Expression Source #

inE :: Expression -> [Expression] -> Expression Source #

IsSql99AggregationExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql99ExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql99FunctionExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql2003NthValueExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql2003LeadAndLagExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql2003NtileExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql2003EnhancedNumericFunctionsAggregationExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

Methods

stddevPopE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression Source #

stddevSampE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression Source #

varPopE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression Source #

varSampE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression Source #

covarPopE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

covarSampE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

corrE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrSlopeE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrInterceptE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrCountE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrRSquaredE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrAvgXE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrAvgYE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrSXXE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrSXYE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

regrSYYE :: Maybe (Sql92AggregationSetQuantifierSyntax Expression) -> Expression -> Expression -> Expression Source #

IsSql2003EnhancedNumericFunctionsExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

IsSql2003ExpressionSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92AggregationSetQuantifierSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92ExpressionQuantifierSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92ExpressionValueSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92ExpressionSelectSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92ExpressionFieldNameSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92ExpressionCastTargetSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql92ExpressionExtractFieldSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

type Sql2003ExpressionWindowFrameSyntax Expression Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

data TableSource Source #

data Value where Source #

Constructors

Value :: (Show a, Eq a, Typeable a) => a -> Value 

Instances

Instances details
Eq Value Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

Methods

(==) :: Value -> Value -> Bool #

(/=) :: Value -> Value -> Bool #

Show Value Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

Methods

showsPrec :: Int -> Value -> ShowS #

show :: Value -> String #

showList :: [Value] -> ShowS #

HasSqlValueSyntax Value Bool Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Double Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

(TypeError (PreferExplicitSize Int Int32) :: Constraint) => HasSqlValueSyntax Value Int Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Int16 Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Int32 Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Int64 Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Integer Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

(TypeError (PreferExplicitSize Word Word32) :: Constraint) => HasSqlValueSyntax Value Word Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Word16 Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Word32 Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Word64 Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value String Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value ByteString Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value UTCTime Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Text Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value LocalTime Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value TimeOfDay Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value Day Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value SqlNull Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

HasSqlValueSyntax Value x => HasSqlValueSyntax Value (Maybe x) Source # 
Instance details

Defined in Database.Beam.Backend.SQL.AST

data WindowFrame Source #