adamc@467: table t : { O : option int } adamc@467: adamc@467: fun addNull () = adamc@467: dml (INSERT INTO t (O) VALUES (NULL)); adamc@467: return Done adamc@467: adamc@467: (*fun add42 () = adamc@467: dml (INSERT INTO t (O) VALUES (42)); adamc@467: return Done*) adamc@467: adamc@467: fun main () : transaction page = adamc@467: xml <- queryX (SELECT * FROM t) adamc@467: (fn r => case r.T.O of adamc@467: None => Nada
adamc@467: | Some n => Num: {[n]}
); adamc@467: return adamc@467: {xml} adamc@467: adamc@467: Add a null
adamc@467:
adamc@467: adamc@467: (* Add a 42
*)