Re: Help with a very newbie question...

From: Richard Huxton <dev(at)archonet(dot)com>
To: Pavel Stehule <stehule(at)kix(dot)fsv(dot)cvut(dot)cz>
Cc: Cristian Prieto <cristian(at)clickdiario(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: Help with a very newbie question...
Date: 2005-02-23 16:34:19
Message-ID: 421CB08B.4040807@archonet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Pavel Stehule wrote:
>>If I did the following:
>>SELECT * FROM "Users";
>>I get:
>>
>>userid | passwd
>>----------+--------
>> cristian | hola
>>
>>AND I execute:
>>SELECT getuser('cristian', 'hola');
>>
>>I get:
>> getuser
>>-----------------
>> (cristian,hola)
>>
>
> There are two posibilities
>
> SELECT getuser('cristian','hola');
> SELECT * FROM getuser('cristian','hola') AS (userid varchar, passwd
> varchar);

Or, define your function as ... RETURNS SETOF Users

--
Richard Huxton
Archonet Ltd

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Cristian Prieto 2005-02-23 16:43:13 Re: Help with a very newbie question...
Previous Message Pavel Stehule 2005-02-23 16:07:22 Re: Help with a very newbie question...