Subject Stored Procedures/IBQuery vs Select-Union Script/IBQuery
Author Carv

I have n tables for my data, and I need to obtain records from one or more
tables (say n - 3). I am analyzing the following potential approaches:
(1) have a stored procedure to be called through an IB_Query n-3 times,
where the table id is included as a parameter and the select sentence is
based on an IF THEN structure.
(2) have n different stored procedures to be called through an IB_Query n-3
times, depending on the tables to be read.
(3) generate a query with the UNION operator (Select f1, f2 from t1 where
xxx UNION Select f1,f2 from t2 where yyy ...), and assign it to the SQL
property of an IB_Query.
(4) same as (3) but instead of using an IB_Query use an IB_Script.
I will be grateful for any suggestions on this problem.
Thank you.
Horacio C.