Re: sql query with join and parameter in postgresql function

From: "Philippe Lang" <philippe(dot)lang(at)attiksystem(dot)ch>
To: <pgsql-sql(at)postgresql(dot)org>
Cc: "Michael Glaesemann" <grzm(at)myrealbox(dot)com>
Subject: Re: sql query with join and parameter in postgresql function
Date: 2004-01-16 13:03:26
Message-ID: 6C0CF58A187DA5479245E0830AF84F420AFA28@poweredge.attiksystem.ch
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

> > I thought a view would be more appropriate, but
> > if I'm not wrong, a view does not accept any parameter
> > as input...
>
> But you can just define the view and select it with a WHERE clause
with
> your parameter, just like a normal table. Would that help?

Thanks! That's perfect. I join in a view, and limit in a function, with
a WHERE clause. And no need for any redundant composite type, although I
agree this is not that complicated to use...

Philippe Lang

Browse pgsql-sql by date

  From Date Subject
Next Message jim.bagley@traderonline.com 2004-01-16 18:10:11 Re: Is it possible in PostgreSQL?
Previous Message Michael Glaesemann 2004-01-16 11:44:15 Re: sql query with join and parameter in postgresql function