|
|
|
| Description |
| EDSL for SQL, and SQL generation from Models descriptions
|
|
| Synopsis |
|
|
|
| Documentation |
|
| sql :: Query -> String |
| Get name of field
|
|
| getParameters :: Query -> [SqlValue] |
| Get list of SqlValue's, given in query
|
|
| table :: Model -> Query |
| Simple query -- SELECT * FROM tablename
|
|
| tableR :: SQLTable -> Query |
|
| select :: Query -> [String] -> Query |
| Select only given fields from the table/query
|
|
| onlyFields :: Query -> [String] -> Query |
| Alias for select
|
|
| sgroup :: Query -> String -> Query |
| Group items in query (add GROUP BY part)
|
|
| order :: Query -> [SQLOrder] -> Query |
| Sort items in query (add ORDER BY part)
|
|
| restrict :: Query -> SQLCondition -> Query |
| Restrict query (add the WHERE part)
|
|
| limit :: Query -> (Int, Int) -> Query |
| Limit query (add OFFSET ... LIMIT ... part)
|
|
| countChildren :: Model -> Model -> Query |
| SELECT all items in table and, for each item, count it's subitems
|
|
| insertM :: Model -> Query |
| Generate INSERT query for given model
|
|
| updateM :: Model -> SQLCondition -> Query |
| Generate UPDATE query for the model
|
|
| deleteM :: Model -> SQLCondition -> Query |
|
| aggregate :: Query -> String -> Query |
| Get some aggregate function of query
|
|
| count :: Query -> Query |
| Get count function of query
|
|
| Produced by Haddock version 2.4.2 |