PostgreSQL TO-DO List (fwd)

Started by Bruce Momjianabout 24 years ago4 messagesdocs
Jump to latest
#1Bruce Momjian
bruce@momjian.us

Can someone comment on this? I don't understand it.

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026
#2Vince Vielhaber
vev@michvhf.com
In reply to: Bruce Momjian (#1)
Re: PostgreSQL TO-DO List (fwd)

On Sun, 3 Mar 2002, Bruce Momjian wrote:

Can someone comment on this? I don't understand it.

The example being referred to is here:

http://www.us.postgresql.org/users-lounge/docs/7.2/postgres/plpgsql-examples.html

Scroll to the bottom. Unfortunately I can't go back and read his
comment with the terminal I'm using.

Vince.
--
==========================================================================
Vince Vielhaber -- KA8CSH email: vev@michvhf.com http://www.pop4.net
56K Nationwide Dialup from $16.00/mo at Pop4 Networking
Online Campground Directory http://www.camping-usa.com
Online Giftshop Superstore http://www.cloudninegifts.com
==========================================================================

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Bruce Momjian (#1)
Re: PostgreSQL TO-DO List (fwd)

Bruce Momjian <pgman@candle.pha.pa.us> writes:

Can someone comment on this? I don't understand it.

He's complaining that a whole-row reference to NEW doesn't work
in a plpgsql trigger. He's right.

regards, tom lane

#4Bruce Momjian
bruce@momjian.us
In reply to: Vince Vielhaber (#2)
Re: PostgreSQL TO-DO List (fwd)

Vince Vielhaber wrote:

On Sun, 3 Mar 2002, Bruce Momjian wrote:

Can someone comment on this? I don't understand it.

The example being referred to is here:

http://www.us.postgresql.org/users-lounge/docs/7.2/postgres/plpgsql-examples.html

Scroll to the bottom. Unfortunately I can't go back and read his
comment with the terminal I'm using.

The current query in this section is:

CREATE FUNCTION c_overpaid (EMP, INTEGER) RETURNS BOOLEAN AS '
DECLARE
emprec ALIAS FOR $1;
sallim ALIAS FOR $2;
BEGIN
IF emprec.salary ISNULL THEN
RETURN ''f'';
END IF;
RETURN emprec.salary > sallim;
END;
' LANGUAGE 'plpgsql';

Looks OK to me. Seems it has been updated since the report. I can't
find a mention of fun1 or fun2 anywhere in the docs anymore.

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026