From: Justin B. <jgb...@gm...> - 2007-12-21 16:43:34
|
On Dec 21, 2007 12:26 AM, Bjorn Bringert <bri...@cs...> wrote: > Great, thank you! I'm sorry about the complications. I've now pushed > your patch. > > > So, what are you working on now? > No problem. I'm interested in using haskelldb to generate SQL for a PHP data-access layer, so I've now added named parameters as another expression type. PHP's odbc family of functions support "prepared" statements with parameters, but they are indicated by position only. That means its very important that I can get the list of parameters in a query in the same order as they will appear in the SQL text. Ideally, I could re-use the pretty-printing framework but that is a pretty big engineering task. I settled on generating them from the intermediate SqlSelect values. Not idea but safe enough. Things I'd like to do still: * Proper joins (starting with inner join) * Representation of foreign-key relationships (ideally extracted from the DB) * Tests We'll see how far I get ... Any ideas or suggestions are welcome! Justin |