To Stored Procedure or not to stored procedure

To Stored Procedure or not to stored procedure

Post by cksanj.. » Tue, 13 Jul 1999 04:00:00



I'm working on an interface for our reports. The source of the reports
are recordsets. Currently, the sql statements are embeded in the
program. To run a report, our users select several criteria and show
the report based on the criteria built. I'm thinking of creating a sp
to return the recordset. One problem I would encounter with sp is that
the parameters have to be OR-ed.
For instance, my sp requires two parameters, state and id. If they want
to run by:
(state = CA and id = 12) or (state = TX and id 40).
How would would I make my parameters to be OR-ed.

Should I just create a COM-component?

Thanks!

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.

 
 
 

1. To stored procedure or not to stored procedure

I'm working on an interface for our reports. The source of the reports
are recordsets. Currently, the sql statements are embeded in the
program. To run a report, our users select several criteria and show
the report based on the criteria built. I'm thinking of creating a sp
to return the recordset. One problem I would encounter with sp is that
the parameters have to be OR-ed.
For instance, my sp requires two parameters, state and id. If they want
to run by:
(state = CA and id = 12) or (state = TX and id 40).
How would would I make my parameters to be OR-ed.

Should I just create a COM-component?

Thanks!

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.

2. ontape problem

3. Calling a Java Stored Procedure from another Java Stored Stored Procedure

4. ERROR when inserting a record contain single quote.

5. Stored procedures calling stored procedures....

6. License Question (SQL Performance)

7. Many Simple Stored Procedures VS. Few Complex Stored Procedures

8. Delphi Availability (was DBase, Paradox, Access or Fopro???)

9. How to call an Oracle Stored procedure from MSSQL Server Stored Procedure

10. Using Stored Procedure's results in a Stored Procedure

11. Stored Procedure calling Stored Procedure

12. return select values in stored procedure to a calling stored procedure

13. Stored Procedure calling a Stored Procedure