add support for values
This commit is contained in:
parent
4330b3d7e0
commit
c52334943f
5 changed files with 18 additions and 4 deletions
tools/Language/SQL/SimpleSQL
|
@ -122,7 +122,7 @@ queries section
|
|||
|
||||
> ,"SELECT DISTINCT select_list t"
|
||||
|
||||
> --,"VALUES (1, 'one'), (2, 'two'), (3, 'three');" -- values list
|
||||
> ,"VALUES (1, 'one'), (2, 'two'), (3, 'three');"
|
||||
|
||||
> ,"SELECT 1 AS column1, 'one' AS column2\n\
|
||||
> \UNION ALL\n\
|
||||
|
@ -130,8 +130,7 @@ queries section
|
|||
> \UNION ALL\n\
|
||||
> \SELECT 3, 'three';"
|
||||
|
||||
> --,"SELECT * FROM (VALUES (1, 'one'), (2, 'two'), (3, 'three')) AS t (num,letter);"
|
||||
> -- values list
|
||||
> ,"SELECT * FROM (VALUES (1, 'one'), (2, 'two'), (3, 'three')) AS t (num,letter);"
|
||||
|
||||
> ,"WITH regional_sales AS (\n\
|
||||
> \ SELECT region, SUM(amount) AS total_sales\n\
|
||||
|
|
|
@ -23,6 +23,7 @@ These are a few misc tests which don't fit anywhere else.
|
|||
> ,limit
|
||||
> ,combos
|
||||
> ,withQueries
|
||||
> ,values
|
||||
> ]
|
||||
|
||||
|
||||
|
@ -185,3 +186,10 @@ These are a few misc tests which don't fit anywhere else.
|
|||
> ms1 = ms "a" "t"
|
||||
> ms2 = ms "a" "u"
|
||||
> ms3 = ms "a" "x"
|
||||
|
||||
> values :: TestItem
|
||||
> values = Group "values" $ map (uncurry TestQueryExpr)
|
||||
> [("values (1,2),(3,4)"
|
||||
> ,Values [[NumLit "1", NumLit "2"]
|
||||
> ,[NumLit "3", NumLit "4"]])
|
||||
> ]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue