From: | Roland Roberts <roland(at)astrofoto(dot)org> |
---|---|
To: | pgsql-sql(at)postgresql(dot)org |
Subject: | Re: PL/pgSQL examples NOT involving functions |
Date: | 2001-11-15 21:21:33 |
Message-ID: | m2snbfg276.fsf@tycho.rlent.pnet |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-docs pgsql-sql |
>>>>> "Josh" == Josh Berkus <josh(at)agliodbs(dot)com> writes:
Josh> Please do not cross-post to multiple lists.
Hmm, there were some complaints recently on the hackers list about
things being posted on only one list. And a significant chunk of the
mail I am getting from lists shows it was posted to more than one
list.
>> How can I write a few lines of PL/pgSQL which do not involve
>> creating a function? I can find no examples of this in the
>> docs, but say I would like to do something like
Josh> You can't. PL/pgSQL, like PL/Perl and PL/Tcl, may only be
Josh> used in functions.
So how would I convert an insert to an update when I detect a tuple is
already present in the database? Do I have to write the whole thing
in Perl/Tcl/whatever and do the conversion there?
roland
--
PGP Key ID: 66 BC 3B CD
Roland B. Roberts, PhD RL Enterprises
roland(at)rlenter(dot)com 76-15 113th Street, Apt 3B
roland(at)astrofoto(dot)org Forest Hills, NY 11375
From | Date | Subject | |
---|---|---|---|
Next Message | Aasmund Midttun Godal | 2001-11-15 21:50:49 | Re: [SQL] PL/pgSQL examples NOT involving functions |
Previous Message | Josh Berkus | 2001-11-15 20:54:32 | Re: PL/pgSQL examples NOT involving functions |
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew G. Hammond | 2001-11-15 21:23:16 | Re: INSERT question |
Previous Message | Josh Berkus | 2001-11-15 20:54:32 | Re: PL/pgSQL examples NOT involving functions |