Re: Is this legal SQL? Is it a good practice? - Mailing list pgsql-general

From Carlos Moreno
Subject Re: Is this legal SQL? Is it a good practice?
Date
Msg-id 412BBCAE.9080902@mochima.com
Whole thread Raw
In response to Re: Is this legal SQL? Is it a good practice?  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-general
Peter Eisentraut wrote:

>>I just noticed that from a C or C++ program using
>>libpq or libpq++, I can send *one* command that
>>contains several SQL statements separated by
>>semicolon.
>
>>But I'm wondering -- is this a PostgreSQL extension,
>>or is it "legal SQL"?
>
> The whole libpq API is made up out of thin air, so it's not conforming
> to any public standard.

Oh, wait.  Though you didn't say it explicitly, I guess
you're implying that it is libpq the one that splits the
thing into the individual SQL statements and then send
each of those to the backend?  (wrapped around a
transaction?)

>>In particular, I'm wondering
>>if it is a feature that in the future you might
>>decide to eliminate for not being ANSI-SQL compliant.
>
> Because of the above, that cannot be a reason for eliminating any
> interfaces.

Well, I was under the impression that the backend would
receive *one* command with *one* string that contains
all the SQL's separated by semicolons.  This is what I
thought might be removed in future releases, if it is
considered that it's an unnecessary extension, etc.

Thanks,

Carlos
--

pgsql-general by date:

Previous
From: Bill Moran
Date:
Subject: Re: Upgrading PostgreSQL 7.1.3
Next
From: "Gavin M. Roy"
Date:
Subject: Re: Gentoo for production DB server?