Re: Feature request: include script file into function body (better syntax)

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Steve White <swhite(at)aip(dot)de>
Cc: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: Feature request: include script file into function body (better syntax)
Date: 2011-02-01 19:35:01
Message-ID: 1161.1296588901@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Steve White <swhite(at)aip(dot)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. 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.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2011-02-01 19:36:13 Re: Feature request: include script file into function body
Previous Message Tom Lane 2011-02-01 19:31:02 Re: Feature request: include script file into function body