Boost logo

Boost :

Subject: Re: [boost] sqlpp11: SQL for C++
From: Roland Bock (rbock_at_[hidden])
Date: 2013-11-12 08:16:59


On 2013-11-12 04:26, Tim Keitt wrote:
> On Sat, Nov 9, 2013 at 4:03 PM, Roland Bock <rbock_at_[hidden]> wrote:
>
[snip]
>>
>>
> This is an interesting thread and I thought I'd comment.
>
> I am a pretty heavy user of postgresql/postgis (spatial extension) in my
> work. I wrote the first R package to access postgresql and contributed to
> the current R DBI package. I did a proof-of-concept (= not very pretty ;-)
> embedding of the Boost Graph Library in postgresql replacing local storage
> with prepared queries called on demand.
>
> I have to say when I look at this, I don't really want to learn another
> SQL. I am perfectly happy to send query strings to the database and let it
> parse them. I can debug these separate from my C++ code. I think for
> complex queries (recursive with anyone?) it would be quite difficult to get
> the C++ right.
Could you send me a complex/recursive example? I'd be interested in a
comparison, of course.

The debugging topic is interesting. Obviously, sqlpp11 can be used to
print query strings. The current connectors do that, when used in debug
mode.

Personally, I believe that the way that sqlpp11 yields results (members
of a struct instead of positional entries in a container) and the
compiler support in constructing and maintaining queries outweigh having
the exact textual representation of the query in the source code. But
that is certainly a matter of taste.

>
> What I would really like is a mapping of binary cursors to iterator
> concepts + easy type-safe endian-aware customizable data conversion. But
> that's my bias. I've always liked mapping on-demand data to common
> interfaces.
I'll have to read up on binary cursors, that is not my core competence...
>
> But your use cases are probably different and I can see how this would be
> very useful to some.

Thanks and regards,

Roland


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk