Mercurial > urweb
diff tests/policy.ur @ 1206:772760df4c4c
Parsing more of WHERE
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Sun, 04 Apr 2010 17:44:12 -0400 |
parents | 7cd11380cdf1 |
children | ae3036773768 |
line wrap: on
line diff
--- a/tests/policy.ur Sun Apr 04 17:18:41 2010 -0400 +++ b/tests/policy.ur Sun Apr 04 17:44:12 2010 -0400 @@ -12,7 +12,8 @@ FROM fruit) policy query_policy (SELECT order.Id, order.Fruit, order.Qty FROM order, fruit - WHERE order.Fruit = fruit.Id) + WHERE order.Fruit = fruit.Id + AND order.Qty = 13) fun main () = x1 <- queryX (SELECT fruit.Id, fruit.Nam @@ -21,7 +22,8 @@ x2 <- queryX (SELECT fruit.Nam, order.Qty FROM fruit, order - WHERE fruit.Id = order.Fruit) + WHERE fruit.Id = order.Fruit + AND order.Qty = 13) (fn x => <xml><li>{[x.Fruit.Nam]}: {[x.Order.Qty]}</li></xml>); return <xml><body>