- This topic is empty.
Viewing 1 post (of 1 total)
Viewing 1 post (of 1 total)
- You must be logged in to reply to this topic.
Arthur Wang Digital Blog
Home › Forums › ABAP Programming › Optimization of Codes
What steps do you take regarding optimization?
—
First I will look at any index fields available in that table.
Second thing is not to use costly select statements to get the data
For example:
Using Select <fld1> <fld2>……<fldn> into corresponding fields of table <itab>
From <table>
Where <conditions>
Is better than
Select * into tab-fld1, itab-fld2……..itab-fldn
From <table>
Where <conditons>
Endselect.
Third thing is if there are more than one table then I will use Joins.
Example: Select EKKO~EBELN
EKKO~LIFNR
EKPO~EBELP
EKPO~MATNR
EKPO~MENGE
Into corresponding fields of table <itab>
From ( EKKO as EKKO inner join EKPO as EKPO
On EKKO~EBELN = EKPO~EBELN )
Where<Conditons>.