Subject How a stored procedure exectute?
Author hfsnell
Dear experts!
I supposed that a stored procedure execute and return a temporary
table. However, I am wrong! When I execute the following SQL:
select * from mysp();
it costs about 1 second.
select * from mysp() where t=100
it costs about 1 second
select * from mysp() where t=110
it costs 4 second.
I try many times and get same results.
I use IBExpert to make analysis, I found that the number of indices
read when the stored procedure executes are differnts at last two cases.
Please help me!