Mercurial > urweb
comparison lib/ur/basis.urs @ 1070:e933297c4e24
Tweaking SQL parsing and typing
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Sun, 13 Dec 2009 10:13:06 -0500 |
parents | 757dbac0454d |
children | 26197c957ad6 |
comparison
equal
deleted
inserted
replaced
1069:757397bb9609 | 1070:e933297c4e24 |
---|---|
318 | 318 |
319 val sql_query1 : tables ::: {{Type}} | 319 val sql_query1 : tables ::: {{Type}} |
320 -> grouped ::: {{Type}} | 320 -> grouped ::: {{Type}} |
321 -> selectedFields ::: {{Type}} | 321 -> selectedFields ::: {{Type}} |
322 -> selectedExps ::: {Type} | 322 -> selectedExps ::: {Type} |
323 -> {Distinct : bool, | 323 -> empties :: {Unit} |
324 -> [empties ~ selectedFields] | |
325 => {Distinct : bool, | |
324 From : sql_from_items tables, | 326 From : sql_from_items tables, |
325 Where : sql_exp tables [] [] bool, | 327 Where : sql_exp tables [] [] bool, |
326 GroupBy : sql_subset tables grouped, | 328 GroupBy : sql_subset tables grouped, |
327 Having : sql_exp grouped tables [] bool, | 329 Having : sql_exp grouped tables [] bool, |
328 SelectFields : sql_subset grouped selectedFields, | 330 SelectFields : sql_subset grouped (map (fn _ => []) empties ++ selectedFields), |
329 SelectExps : $(map (sql_exp grouped tables []) | 331 SelectExps : $(map (sql_exp grouped tables []) |
330 selectedExps) } | 332 selectedExps) } |
331 -> sql_query1 tables selectedFields selectedExps | 333 -> sql_query1 tables selectedFields selectedExps |
332 | 334 |
333 type sql_relop | 335 type sql_relop |