Re: [SQL] Problem with FOR SELECT in plpgsql function

2004-02-20 Thread Richard Huxton
On Friday 20 February 2004 10:07, Plant Thomas wrote: > I have a problem with the following function: [snip] > > This function sometimes returns null even if there is a record in the > database for the corrisponding id. > This happens only when there is only one record for the corrisponding id > va

[SQL] Problem with FOR SELECT in plpgsql function

2004-02-20 Thread Plant Thomas
I have a problem with the following function: CREATE OR REPLACE FUNCTION "weiterbildung"."f_termine_uhrzeit" (integer) RETURNS text AS' DECLARE id ALIAS for $1; dat RECORD; uhrzeiten text; BEGIN uhrzeiten = ; FOR dat IN SELECT vormittag_a, vormittag_e, nach