batching commands with libpq - Mailing list pgsql-novice

From yamt@mwd.biglobe.ne.jp (YAMAMOTO Takashi)
Subject batching commands with libpq
Date
Msg-id 20101228050805.5FFC219CFB3@mail.netbsd.org
Whole thread Raw
Responses Re: batching commands with libpq
List pgsql-novice
hi,

is there any way to send multiple commands together (ideally in a single
network packet), and then wait for their results, using libpq?  i want to
save extra round-trips.  while postgresql's fe-be on-wire protocol seems
to allow it (is it right?), i couldn't find a way with libpq.

PQsendQuery(conn, "select timeofday();select timeofday();select timeofday();");
seems to work, but i want to use extended protocol.

YAMAMOTO Takashi

pgsql-novice by date:

Previous
From: wolfang
Date:
Subject: Send parameters using Shell script to PostgreSQL
Next
From: Aarni
Date:
Subject: Re: Send parameters using Shell script to PostgreSQL