From: Steve White <swhite@aip.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Kevin Grittner <Kevin.Grittner@wicourts.gov>
Cc: pgsql-bugs@postgresql.org
Subject: Re: Feature request: include script file into function body (better syntax)
Date: Tue, 1 Feb 2011 21:04:10 +0100
Message-ID: <20110201200410.GB8252@cashmere.aip.de> (raw)
In-Reply-To: <1161.1296588901@sss.pgh.pa.us>
References: <20110201112120.GA1327@cashmere.aip.de>
<26900.1296576145@sss.pgh.pa.us>
<20110201164422.GA3023@cashmere.aip.de>
<4D47EB12020000250003A0EE@gw.wicourts.gov>
<20110201185004.GA7511@cashmere.aip.de>
<20110201190927.GB7511@cashmere.aip.de>
<1161.1296588901@sss.pgh.pa.us>
Hi Tom,
I already agreed to Kevin's proposed syntax, and it is better than
my suggestion, but mine isn't quite as crazy as you make out.
On 1.02.11, Tom Lane wrote:
> Steve White <swhite@aip.de> writes:
> > Try this instead:
>
> > ================================================
> > CREATE OR REPLACE FUNCTION
> > myfunc( ... )
> > RETURNS VOID AS '#PGSQL_IMPORT filename' LANGUAGE PLPYTHONU;
> > ================================================
>
> I think having psql decide that string literals mean something other
> than their face value is Right Out --- it would bite you on the rear
> just when you least expect it.
Interesting idea... but why would psql make this decision?
Did somebody suggest that off-line?
I said that the script interpreter might do this...
But the other syntax is better anyway.
> And the notion of the behavior being
> language-dependent is right out to the fourth power. But see my
> alternative proposal to Kevin just now.
>
--
| - - - - - - - - - - - - - - - - - - - - - - - - -
| Steve White +49(331)7499-202
| E-Science Zi. 27 Villa Turbulenz
| - - - - - - - - - - - - - - - - - - - - - - - - -
| Astrophysikalisches Institut Potsdam (AIP)
| An der Sternwarte 16, D-14482 Potsdam
|
| Vorstand: Prof. Dr. Matthias Steinmetz, Peter A. Stolz
|
| Stiftung privaten Rechts, Stiftungsverzeichnis Brandenburg: III/7-71-026
| - - - - - - - - - - - - - - - - - - - - - - - - -
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: swhite@aip.de, tgl@sss.pgh.pa.us, Kevin.Grittner@wicourts.gov
Subject: Re: Feature request: include script file into function body (better syntax)
In-Reply-To: <20110201200410.GB8252@cashmere.aip.de>
References: <20110201112120.GA1327@cashmere.aip.de> <26900.1296576145@sss.pgh.pa.us> <20110201164422.GA3023@cashmere.aip.de> <4D47EB12020000250003A0EE@gw.wicourts.gov> <20110201185004.GA7511@cashmere.aip.de> <20110201190927.GB7511@cashmere.aip.de> <1161.1296588901@sss.pgh.pa.us> <20110201200410.GB8252@cashmere.aip.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox