|Subject||RE: [firebird-support] How do you dynamically build a SQL Statement in a Stored Procedure?|
> I am trying to build a resultset from a list of ID Values. I wouldif you're doing this all the time from your apps, then I would suggest you
> like to do this in a stored procedure rather than in Delphi code
> because there are lots of queries to build the resultset, so it should
> be more efficient to do it in the database.
> 1) How do I pass a stored procedure a list of ID values?
> 2) How cam I dynamically build a statement like Select X from Table
> where ID value in ( Value list )?
let the db do it with a where clause. Add another field(s) to allow these
If this IN clause becomes big then you're on the wrong path anyway