From: | "Cornelia Boenigk" <c(at)cornelia-boenigk(dot)de> |
---|---|
To: | "pgsql-general" <pgsql-general(at)postgresql(dot)org> |
Subject: | Question to CREATE FUNCTION |
Date: | 2002-03-01 19:08:20 |
Message-ID: | 002501c1c154$cca40740$aec1fea9@zwerg98 |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hi all
I defined the following function:
CREATE FUNCTION ka(member)
RETURNS member AS
'UPDATE member SET m_email = ''unbekannt'' WHERE m_email = NULL:
SELECT * FROM member;'
LANGUAGE 'sql';
If I call
SELECT ka(member) FROM member;
ka
-------------
12257440
.....
I get this number as many times as the table consists rows (no matter
weather they were updated or not). Could anybody tell me what kind of
result this is? What does this number mean?
If I use the notation with $1 like in the Programmers Guide in chapter
13.1.3 I get a parsing error. (??)
Could anybody explain this behaviour?
Thanks and greetings
Conni
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2002-03-01 20:02:36 | Re: passwd / pg_hba.conf |
Previous Message | Patrick Welche | 2002-03-01 18:53:20 | passwd / pg_hba.conf |