libpq - mostrar resultado como char*

From: Ruben Fitó <r(dot)fito(at)ubiquat(dot)com>
To: "pgsql-es-ayuda(at)postgresql(dot)org" <pgsql-es-ayuda(at)postgresql(dot)org>
Subject: libpq - mostrar resultado como char*
Date: 2017-09-27 12:30:09
Message-ID: CANiYpQyFCQxQFZDukR_mmEV9x4AzPYXZvOaYBK6mu8y1oBm3rA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

Hola lista,

Una pregunta rápida.

He visto que la librería libpq (ANSI C) permite imprimir el resultado de
una QUERY con PQprint.

La documentación muestra que se utiliza FILE como canal de salida.

Quizás me falte experiencia con FILE pero cómo puedo obtener el resultado
como string(char*)?

He probado un buen rato y no encuentro la solución.

Gracias de antemano.

Saludos

--
*Ruben Fitó *
Software Engineer
[image: Ubiquat Technologies, SL]
r(dot)fito(at)ubiquat(dot)com <j(dot)catarineu(at)ubiquat(dot)com>
www.ubiquat.com
Tota la informació continguda en aquest document i arxius adjunts és
CONFIDENCIAL protegida per llei de secret comercial. Si l'ha rebut per
error, si us plau elimini'l i posi's en contacte amb l'emissor.

All information contained in this document and any attachments are
CONFIDENTIAL and protected under trade secret laws. If you receive this
message by mistake, please delete it and notify it immediately to the
sender.

Responses

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message Carlos Martinez 2017-09-27 14:50:50 Re: PostgreSQL 10 y conexión a MS SQL Server
Previous Message Alvaro Herrera 2017-09-27 10:42:55 Re: PostgreSQL 10 y conexión a MS SQL Server