Boost logo

Boost :

Subject: Re: [boost] sqlpp11: SQL for C++
From: Roland Bock (rbock_at_[hidden])
Date: 2013-11-11 10:01:26

On 2013-11-11 15:36, Edward Diener wrote:
> On 11/11/2013 7:53 AM, Roland Bock wrote:
>> On 2013-11-11 11:27, Rodrigo Madera wrote:
>>> On Sat, Nov 9, 2013 at 8:03 PM, Roland Bock <rbock_at_[hidden]> wrote:
>>>> Hi,
>>> Hello,
>>> Just curious over some points:
>>> Does it support binary transfers over the wire?
>> The library creates template expression trees for the queries. As of
>> now, the tree is serialized and sent to the database connector when you
>> call
>> Result rows are currently to be returned from the connector's result
>> object as const char**, see database_api/api.h.
> You are kidding ? Is std::vector<std::string> too advanced ? Why C++
> programmers are still using C null-terminated strings I will never
> understand.
No kidding. The database client libraries I've used so far are C
libraries yielding char**. That is why the current connector interface
also uses const char**. BTW: These are typically not null-terminated but
are delivered with a size_t* or similar to inform about the length...


 1. As a user of the library you don't get in touch with those. The
    members of a row are NOT char*, of course. You get integers as
    integers, floats as floats and of course you get text as
    std::string. I wouldn't dare to use char* there ;-)
 2. It would be really easy to add additional interface options so that
    the connector library could yield std::vector<std::string>



Boost list run by bdawes at, gregod at, cpdaniel at, john at