Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
Vishakha
Starting Member
40 Posts |
Posted - 2006-05-30 : 05:59:43
|
| I have to generate reports based on certain criteria, here is what I am doing,I have nested UDFs, I have a UDF that calculates stores the values from the first level of tables into another table variable.Then there is another round of calculations in the select and use of some other tables in the schema to come up with the next level. for each calculation, previous UDF is called extensively to get the value.This process continues till my report level is reached.Basic approach is get the values from the tables and add the computed values to the table variable. use the udf to get the data from the table variable do some more computation and continue ...The maximum level of iteration is 6.My questions are1. As I am using UDFs within select it is going to hamper the performance significantly what is the other approach, I thought of using derived tables and stored procedures but we can't have derived tables data when we have nested stored procs. temporary tables will not help as we have to continuosly create and drop tables.2. Is there any limit to the size when using table variables. As my reports are going to be really big. |
|
|
kristianwhittick
Starting Member
12 Posts |
Posted - 2006-06-07 : 05:13:41
|
| Please give example data and some code to show what you are trying to do. |
 |
|
|
|
|
|