Skip site navigation (1) Skip section navigation (2)

Re: psql, remove include of psqlscan.c

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Karl O(dot) Pinc" <kop(at)meme(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: psql, remove include of psqlscan.c
Date: 2012-09-27 19:28:49
Message-ID: 1167.1348774129@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackers
"Karl O. Pinc" <kop(at)meme(dot)com> writes:
> What I'm thinking of in libpq is the ability to give it big string
> with many sql statements and have it hand back each statement
> so the client can then submit it to the server for execution.
> What I really _want_ is to be able get a bit string of many
> sql statements from the user and return the results, statuses,
> etc. of executing each statement.  Just what psql does when,
> say, fed a file from stdin.

Just as a note --- I believe you can get that result today with
PQsendQuery followed by a PQgetResult loop.  There's no need to
provide an API that splits the string first.

			regards, tom lane


In response to

Responses

pgsql-hackers by date

Next:From: Alvaro HerreraDate: 2012-09-27 19:35:27
Subject: Re: pg_signal_backend() asymmetry
Previous:From: Pavel StehuleDate: 2012-09-27 19:09:19
Subject: Re: proposal - assign result of query to psql variable

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group