-
Notifications
You must be signed in to change notification settings - Fork 3
Roadmap
- Finalize the test-suite to remove as many bugs as possible.
- Improve quick-start tutorial.
- Perform additional tests against injection.
- Adding new functions (support of dates, etc.)
New syntax implementation insuring the grammatical correctness of statements. For example, it is not possible to write anymore a statement such as (as a FROM clause cannot be preceded by a another FROM clause):
bad =
select (//*)
|> from (table "films")
|> from (table "actors")
|> end
Pretty print implementation using parseP function.
Replaced composition function (/++) by a State monad for composing the different clauses of a query. Concretely:
myQuery :: Select [[Undefined]] a
myQuery = select (//*) /++ from (table "People")
is now:
myQuery :: Query [[Undefined]] a
myQuery = do
select (//*)
from $ table "People"
GADTs define an extra phantom type which is the SQL type of a columns or a value. It allows to perform static type checks of the SQL statements.
Functions relying on columns/values of unspecified type are now grouped in the Ext module. It allows the user to choose or not to stay with queries for which all values / columns have a type or not.
The data structure has been re-worked to use phantom type. The driver (MariaDb, PostgreSQL, SqLite) is defined as the phantom type.
With this data-structure the parser class can detect which parser to use. Instead of multi-parameters type classes, parsers are now defined as records types.
When a SQL keyword is also used in Haskell, it's now followed by "", so for example: "where".
Have the association of the different parts of the SQL query using lenses, so one can write the following:
select ["id", "name"] & from "table1" & where_ ("id" > (1::Int))
Where "&" is the backward function application.
This was an all nice idea, but the problem is the types when you try to compose the result of orderBy with a limit, because now orderBy function is a partially applied lens!!!
[Note 15 June 2015: finally a State monad has been used for the composition]
Functions part of the prelude overwritten, so one can write directly in the natural way ">", "<", etc.
This was a bit of a crazy idea...