ABAP Tips

ABAP tables
There are three tables types in SAP, i.e : transparent, pooled and cluster. The tables which hold application data are only transparent tables that you use in day-to-day basis. So, don't worry about the others.

Link between table, field, data element and domain
A table is composed of fields. A field links to data element (DE). A data element links to a domain (DM).
What is data element ? field labels, F1 help.
What is data domain ? field length, data type.

What is the best way to create a table in SAP ?
You may create a table starting from DM, DE to a table or in an opposite way. The first one is called bottom-up approach (intuitive but cumbersome). The second one is called top-down approach (easier and practical).

How to create DE in SAP R/3 release 4.7 and above ?
You experience confused in reading ABAP books, perhaps the old editions ones. Some terms, some screens and some procedures may differ if you use the latest release of SAP IDES (Internet Demo and Evaluation Systems). So of course, there are some differences in SAP ECC 6.0 and SAP R/3 4.7 versions. One hint for compatibility view : in SAP R/3 release 3.0, you came to create DE in "Object Name" field. But in SAP R/3 release 4.7, you call it "Data Type".

How to show line number in ABAP editor environment ?
Follow this path : utilities > settings > back-end editor > with line numbering

How to put comments in ABAP editor ?
Use * (asterisk) for the entire line of comments, and use " (double quote) to put a comment at the end of a syntax.

How to write in new line ?
Pascal language use [writeln] to begin a new line, but how about in ABAP ? use backslash, i.e [write /]

What is a chain operator ?
A chain operator [ : ] is used to represent efficiently repeated syntax such as ...
tables lfa1.
tables lfa2.
becomes in one line i.e tables : lfa1, lfa2.

How to terminate endless loop ?
Restart the application server....and you will have a phone rang from your supervisor and your users he..he..he...it's not a joke :( Endless loop happens when you do not put a brake in between of looping statement. What is looping statement ? DO...ENDDO, WHILE...ENDWHILE. I urge you to create a new session before you practice using looping statement. How to create a new session ? Follow this path : system > create session. In case one of your session experience in an endless loop, just turn off one session and use another session. So the best answer to this very specific problem...use a preventive solution above ! Have a try...Proof it by making an endless loop :D

All SAP products are trademark of SAP AG. This blog is not affiliated with nor endorsed by SAP AG.