09-17-2008 11:45 AM
I have to retrieve all records from VBFA table.
SELECT <fields> from VBFA into table t_vbfa.
no condition is there to place in where condition.
how can i improve the performance.
Thank you.
Lalitha
Edited by: lalitha botla on Sep 17, 2008 1:11 PM
Edited by: lalitha botla on Sep 17, 2008 1:11 PM
09-17-2008 12:12 PM
Hi,
As you have mentioned that there is no condition for selection, in that case make sure that you don't fetch any un-necessary fields. Also, store the selection result in some internal table for further usage as executing these kind of queries (databse fetch) repeatedly is not wise.
Thank you.
09-17-2008 12:18 PM
I am taking only required fields( only five fields ) and storing
the selection result in internal table t_vbfa.
09-17-2008 12:29 PM
Hi Lalitha,
Instead of writing select query you can use FM SD_VBFA_SELECT, I think this would be faster compare to select query.
Just compare your report with this FM.
Thanks & Regards,
Nagaraj Kalbavi
09-18-2008 10:34 AM
Hi,
why?
What do you think the FM is doing ? It will execute SELECT to the database.
(It may somewhat little slower if they do it in a loop)
You can't beat a SELECT like that. If you can do it in one statement - do it!
For a real boost you can have some database hints like PARALLEL or for database buffering.
but...the database has to support it, your DB server has to have enough resources and sometimes it makes
no sense to do in PARALLEL because of the tradeoff between the coordinating of parallel processes and the amount of rows to be selected.
bye
yk
09-17-2008 12:25 PM
better u will give blank ranges and
client as restriction parameter
09-17-2008 1:09 PM
can you please explain me about blank ranges?
does it affect the performance?
09-17-2008 2:35 PM
Run it in the background. There's not much you can do.
Rob
09-18-2008 6:23 AM
Hi Lalitha,
use package size in select statement with appending option or in to option according to your requirement to store all the contents of vbfa table in to an internal table.
Use the following link which helps you to write a query using package size.
http://help.sap.com/saphelp_scm50/helpdata/en/fc/eb39eb358411d1829f0000e829fbfe/content.htm
Thanks,
Naveen Kumar.