On Wed, Jun 11, 2014 at 1:20 AM, Raimo Jormakka <raimo.jormakka@xxxxxxxxx> wrote: > Hi, > > What is the recommended way of accessing structured data-types (especially > JSONB and HSTORE) using libpq? It seems that by default JSONB data for > example is returned as text. > > Is it not possible to have binary access to these data-types? If it is > possible, then how do I do it exactly as the only thing I get from libpq is > a void-pointer? check out libpqtypes: http://libpqtypes.esilo.com/. it gives C client side representations of most common types including hstore. jsonb is not supported yet but the library is pluggable to add support for new types. merlin