[Haskell-cafe] Consensus about databases / serialization
gale at sefer.org
Thu Jan 3 16:09:03 EST 2008
>>... to control the precise SQL that is generated. In practice,
>> you almost always have to do some tweaking that is
>> at least DB-dependent, and often application dependent.
Peter Verswyvelen wrote:
> Can't the same be said regarding SQL itself? It sometimes needs tweaking.
> That's the problem with any high level abstraction no?
Certainly. In an ideal world, you could just write your queries
in straightforward SQL and the DB would figure out what to
do. But in real life, that is not how it works.
So that complexity then gets passed up to the Haskell
interface layers. Again, in an ideal world you would like to
imagine that a high-level interface like haskelldb would
be smart enough to compile any relational algebraic
expression into SQL that will do the Right Thing for the
But that would be very difficult. For example - there may
be things you need to tweak that are both
application-dependent and DB dependent.
So to be usable in a serious DB project, there
would have to be some kind of hooks that would allow
you to tweak the SQL. After doing that - what have we
gained by taking the high-level approach to begin with?
I'm not sure.
I would like to hear about people's thoughts and experiences
More information about the Haskell-Cafe