pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
control structures in plpgsql
3+ messages / 2 participants
[nested] [flat]

* control structures in plpgsql
@ 2003-06-12 14:13 Robert Treat <xzilla@users.sourceforge.net>
  2003-06-12 14:24 ` Re: control structures in plpgsql Stephan Szabo <sszabo@megazone23.bigpanda.com>
  0 siblings, 1 reply; 3+ messages in thread

From: Robert Treat @ 2003-06-12 14:13 UTC (permalink / raw)
  To: pgsql-sql

Does anyone know if there is support for "IF x OR y THEN" syntax in
plpgsql? The docs just say IF [boolean expression] then. which loosely
interpreted could allow for an OR, but I couldn't seem to get it to
work. TIA,

Robert Treat

-- 
Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL




^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: control structures in plpgsql
  2003-06-12 14:13 control structures in plpgsql Robert Treat <xzilla@users.sourceforge.net>
@ 2003-06-12 14:24 ` Stephan Szabo <sszabo@megazone23.bigpanda.com>
  2003-06-12 14:44   ` Re: control structures in plpgsql Robert Treat <xzilla@users.sourceforge.net>
  0 siblings, 1 reply; 3+ messages in thread

From: Stephan Szabo @ 2003-06-12 14:24 UTC (permalink / raw)
  To: Robert Treat <xzilla@users.sourceforge.net>; +Cc: pgsql-sql


On 12 Jun 2003, Robert Treat wrote:

> Does anyone know if there is support for "IF x OR y THEN" syntax in
> plpgsql? The docs just say IF [boolean expression] then. which loosely
> interpreted could allow for an OR, but I couldn't seem to get it to
> work. TIA,

Can you give a full example of what you're trying?  I'm not seeming to
have a problem in 7.3 of saying something with an OR in it apart from
needing to put parentheses around things for ordering in more complicated
cases.





^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: control structures in plpgsql
  2003-06-12 14:13 control structures in plpgsql Robert Treat <xzilla@users.sourceforge.net>
  2003-06-12 14:24 ` Re: control structures in plpgsql Stephan Szabo <sszabo@megazone23.bigpanda.com>
@ 2003-06-12 14:44   ` Robert Treat <xzilla@users.sourceforge.net>
  0 siblings, 0 replies; 3+ messages in thread

From: Robert Treat @ 2003-06-12 14:44 UTC (permalink / raw)
  To: Stephan Szabo <sszabo@megazone23.bigpanda.com>; +Cc: pgsql-sql

On Thu, 2003-06-12 at 10:24, Stephan Szabo wrote:
> 
> On 12 Jun 2003, Robert Treat wrote:
> 
> > Does anyone know if there is support for "IF x OR y THEN" syntax in
> > plpgsql? The docs just say IF [boolean expression] then. which loosely
> > interpreted could allow for an OR, but I couldn't seem to get it to
> > work. TIA,
> 
> Can you give a full example of what you're trying?  I'm not seeming to
> have a problem in 7.3 of saying something with an OR in it apart from
> needing to put parentheses around things for ordering in more complicated
> cases.
> 

You beat me to my "please disregard the previous email" email ;-)

It works (in 7.2 btw), I was just programming in the wrong language
inside my plpgsql function. 

Thanks for taking a look though. 

-- 
Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL




^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2003-06-12 14:44 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-06-12 14:13 control structures in plpgsql Robert Treat <xzilla@users.sourceforge.net>
2003-06-12 14:24 ` Stephan Szabo <sszabo@megazone23.bigpanda.com>
2003-06-12 14:44   ` Robert Treat <xzilla@users.sourceforge.net>

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