Re: [GENERAL] Array Parameters in EXECUTE

2009-06-11 Thread Sim Zacks
sday, June 11, 2009 11:04 AM > To: "Shakil Shaikh" <> > Subject: Re: [GENERAL] Array Parameters in EXECUTE > >>> Here's my general situation: I have a function which takes in an >>> optional ARRAY of Ids as so: >>> >>> RETURN QUERY

Re: [GENERAL] Array Parameters in EXECUTE

2009-06-11 Thread Sim Zacks
> Here's my general situation: I have a function which takes in an > optional ARRAY of Ids as so: > > RETURN QUERY SELECT * FROM a WHERE a.id = ANY(v_ids) or v_ids is null; > If I understand what you are trying to do, if your passed in parameter is null then select * and if there is something t

Re: [GENERAL] Array Parameters in EXECUTE

2009-06-11 Thread Shakil Shaikh
Re added list! -- Sent: Thursday, June 11, 2009 11:04 AM To: "Shakil Shaikh" <> Subject: Re: [GENERAL] Array Parameters in EXECUTE Here's my general situation: I have a function which takes in an optional ARRAY of Ids as so:

Re: [GENERAL] Array Parameters in EXECUTE

2009-06-11 Thread Pavel Stehule
Hello 8.4 suport USING clause - so there is possible use array variable directly. regards Pavel Stehule 2009/6/11 Shakil Shaikh : > Hi, > > Here's my general situation: I have a function which takes in an optional > ARRAY of Ids as so: > > RETURN QUERY SELECT * FROM a WHERE a.id = ANY(v_ids) or