Long running time when generate report [message #153073] |
Wed, 28 December 2005 21:06 |
juicyapple
Messages: 92 Registered: October 2005
|
Member |
|
|
I have created a report, the report flow as below,
1. User parameters are pdate1 and pdate2
2. Query from table A
select input_date from A
where input_date between pdate1 and pdate2
group by input_date
3. Create a function, which will call store procedure
(computation is done within the store procedure)
total := Str_prd.count_volume(input_date);
4. Function return total to the report
When I input pdate1 ='01/10/2005' and pdate2='31/10/2005', big amount of data is retrieved, and report generating will be 'hang'.
Is the condition caused by calling store procedure for each record?
Thanks.
|
|
|
Re: Long running time when generate report [message #153141 is a reply to message #153073] |
Thu, 29 December 2005 07:44 |
Steve Corey
Messages: 336 Registered: February 2005 Location: RI
|
Senior Member |
|
|
Hi -
It could be the function (not having the syntax and the scenerio make it a little difficult to tell) but my hunch is that it is where you placed this function in the report. Is it within one of your groups? Is it a report level function? I had a report run with a formula column containing a couple of cursors and some looping and when I placed it in my top group, the report took more than 1 minute to generate 1 page. When I moved it out of the top group and to report level, it was lightning quick. Check the location and think of how many times the report needs to execute your function.
HTH,
Steve
|
|
|