07-03-2015 7:14 AM
Hi all,
I have made a purchase register which takes a long time to generate the output.It exactly takes 5 min to generate the data for a single day which has only 4 records.I even made a background run using sm37 (for 1 months but still running from 4 days) I did a runtime analysis using SAT for the day which generated 4 records and i got the time taken by the program for fetching bseg data is very high but could not find an unnecessary codes there which could be removed or changed.So kindly help me in solving this problem.
Regards
Nav
07-03-2015 9:38 AM
Hi all,
Thanks all for your replies.I am attaching my codes.
Regards
Nav
07-03-2015 7:26 AM
Hi Nav
Are you able to supply the code of the relevant program you're running.
Is this a custom or SAP Standard program?
Regards
Arden
07-03-2015 7:37 AM
Hi nav,
Since the program trace shows long running time for query on bseg i would recommend you to check somthings:
It would be great if you share your code so that we may be able to help better.
~Tanmay
07-03-2015 7:43 AM
Good old BSEG.
As the others here already said, if you post your code it would be a help... to you.
07-03-2015 8:26 AM
Hi Navratan,
I too faced same problem while fetching data from MSEG( As it has huge data ) using for all entries.
When I approached FS team, they gave me an alternative( other tables ) to fetch the required data.
Ask them is there any alternative for that.Hope it will help you.
Regards,
Omkar.
07-03-2015 9:38 AM
Hi all,
Thanks all for your replies.I am attaching my codes.
Regards
Nav
07-03-2015 1:22 PM
Hi Nav,
First things first. The code is lacking some basic performance improvement techniques.
I would recommend you to take care of the above points and then again run a trace and see the pain points.
~Tanmay
07-03-2015 1:32 PM
Hi Tanmay,
Thanks for your reply I will do the necessary corrections as suggested by you and then let you know.
Regards
Nav
07-03-2015 1:30 PM
Did you notice this good old BSEG is a cluster table, so only actual fields are those of cluster table RFBLG (MANDT, BUKRS, BELNR, GJAHR) so any SELECT that don't provide those key will execute a full table scan...
Hint: Now take a look at so called index table BS[I,A][S,D,K,M] which are actual transparent tables, but this is a FAQ...
Regards,
Raymond
07-03-2015 1:35 PM
Hi Raymond,
Thanks for your reply .I got the thing so would do some changes to it.
Regards
Nav
07-09-2015 8:22 AM
Hi all,
Thanks everyone for your reply.You all were very helpful in sorting out the problem.
Regards
Nav