Professional Documents
Culture Documents
GeneralPerformanceAdviceforSAPABAPOpenSQL
SAPPractical.com
Home (/home/)
1/6
11/9/2016
GeneralPerformanceAdviceforSAPABAPOpenSQL
Blogs (/home/blogs)
Index (/home/indexs)
Login (/home/login)
Registration (/home/regis...
2/1/2016 5:20:59 PM
General Performance Advice for Open SQL - This blog will gives about
performance tuning in ABAP programming. How to optimize your
ABAP SQL? Tips and tricks for select queries. Deducting expensive
SQL for a transaction which can be either custom or standard
transaction. ABAP SQL performance tuning is one of the challenging
area. I am sure below the contents will be a basic for ABAP beginners.
Keep the database hit list small
Wherever possible, you should include all selection conditions in the
WHERE clause, using AND and checking for equality. Do not select a
large dataset and then check it with CHECK. If you want to read the
whole table, you do not have to specify a WHERE condition at all.
Transfer small amounts of data
If you only want to transfer a few elds, use SELECT with a structure,
not SELECT *. Alternatively, you can use one of the views in the ABAP
Dictionary to select data.
SAPPractical.com
Home (/home/)
Use
the aggregate
functions rather than selecting data and grouping
it
Hello
Guest! (/home/login)
yourself. SAP buffering is switched off when you use aggregate
functions.
When you UPDATE a database record, you should only update those
columns that have been changed.
http://www.sappractical.com/home/blogd/generalperformanceadviceforsapabapopensql/
SAP Technical (/sap/saptech)
2/6
11/9/2016
GeneralPerformanceAdviceforSAPABAPOpenSQL
Blogs (/home/blogs)
When you INSERT, UPDATE or DELETE, you should use sets of data
instead of individual table entries. This ensures that the index only has
to be maintained once, which relieves the load on the database.
Index (/home/indexs)
You should only use nested SELECT loops when the hit list in the
outermost level is very small.
Login (/home/login)
Registration (/home/regis...
SAPPractical.com
Home (/home/)
You should use explicit cursor handling for large quantities of data and
logical databases.
Search through small amounts of dataIn WHERE conditions, you
http://www.sappractical.com/home/blogd/generalperformanceadviceforsapabapopensql/
3/6
11/9/2016
GeneralPerformanceAdviceforSAPABAPOpenSQL
Blogs (/home/blogs)
Index (/home/indexs)
Login (/home/login)
Registration (/home/regis...
NOT, OR and IN are not supported by indexes unless all of the elds in
the SELECT clause and WHERE condition are also contained in the
index.
Reduce the database load wherever possible
Saving database in local buffers (see SAP buffering) can save
considerable time in client-server environments, as the access time via
the network is considerably higher than access time via a locally
buffered table.
SAPPractical.com
Home (/home/)
Data
in long
strings
is stored outside the dataset, which means that it
Hello
Guest!
(/home/login)
takes longer to access long strings than to access other data types.
This applies in particular to set operations, and does not apply for
short strings. Next blog will give about how to get trace and analyse
further.
http://www.sappractical.com/home/blogd/generalperformanceadviceforsapabapopensql/
4/6
11/9/2016
GeneralPerformanceAdviceforSAPABAPOpenSQL
further.
Blogs (/home/blogs)
Index (/home/indexs)
Login (/home/login)
Registration (/home/regis...
COMMENTS
LEAVE A COMMENT
Your name
Your email address
Calibri
15
Submit comment
SAPPractical.com
Home (/home/)
RECENT POSTS
Hello
Guest! or
(/home/login)
How
to create
generate a test inbound queue in sap
(/home/blogd/how-to-create-or-generate-a-test-inbound-queuein-sap/)
8/13/2016 12:17:40 AM
11/9/2016
GeneralPerformanceAdviceforSAPABAPOpenSQL
5/26/2016 11:22:26 AM
Blogs (/home/blogs)
Index (/home/indexs)
Login (/home/login)
Registration (/home/regis...
(https://www.facebook.com/sappractical/)
(http://www.SAPPracticalCom.blogspot.com)
(https://plus.google.com/b/115103102431089818132)
(https://twitter.com/sap_practical)
About Us (/home/aboutus)
Contact Us (/home/contactus)
http://www.sappractical.com/home/blogd/generalperformanceadviceforsapabapopensql/
6/6