Some docs

Portnov [2009-07-27 07:57:32]
Some docs
Filename
Framework/ORM/SQL.hs
diff --git a/Framework/ORM/SQL.hs b/Framework/ORM/SQL.hs
index 9086509..58c9c04 100644
--- a/Framework/ORM/SQL.hs
+++ b/Framework/ORM/SQL.hs
@@ -52,11 +52,14 @@ sql' (UpdateQuery table fields values whre) = "UPDATE "++table++" SET "++eqs++wp
 sql' (DelQuery table whre) = "DELETE FROM "++table++wpart
     where wpart = if whre==NoCondition then "" else " WHERE "++(sqlFragment whre)

+-- | Get list of SqlValue's, given in query
+getParameters ::  Query -> [SqlValue]
 getParameters (Query {qWhere=conds}) = params conds
 getParameters (UpdateQuery {uWhere=conds}) = params conds
 getParameters (DelQuery {dWhere=conds}) = params conds
 getParameters _ = []

+params ::  SQLCondition -> [SqlValue]
 params (c :&: d) = concatMap params [c,d]
 params (c :|: d) = concatMap params [c,d]
 params (a :==: b) = appendValues a b
ViewGit