[Haskell-cafe] Re: Web server continued

Mattias Bengtsson moonlite at dtek.chalmers.se
Wed Jan 2 16:36:36 EST 2008

On Mon, 2007-12-31 at 12:36 +0000, Joost Behrends wrote:
> And concerning SQL: I like the parts of the language - all capitalized - as
> landmarks in my code, even in modified forms like:
>  "SELECT number, customer FROM " ++ currcols ++ ....
> Here i see from afar, what the code around this line does.

And the backside of treating SQL as strings, like you do here, is that
you are able to construct malformed SQL and the errors you get from this
can only be handled at runtime. This is the reason HaskellDB (and other
similar projects?) exists. 
I too am not sure that HaskellDB is the perfect solution though. It
provides both type safety and an abstraction. Personally i'd be fine
with just the type safety. Not sure if it's feasible to embed the whole
SQL-syntax in Haskell using just ADT's and combinators though.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20080102/ac76a147/attachment.bin

More information about the Haskell-Cafe mailing list