|Home • Trainings • Quiz • Tips • Tutorials • Functional • Cert Q's • Interview Q's • Jobs • Testimonials • Advertise • Contact Us|
SAP ABAP Pragmas
By Mavee Solutions
Pragmas are program directives that
can be used to hide warnings from various check tools. Pragmas are available
from the ABAP release 7.0 EhP2. Pragmas has replaced Pseudo Comments. Pseudo
Comments are absolute and should no longer be used.
Let us understand Pragmas and Pseudo
For the demo purpose, we have created
the following program:
Let us do the “Extended Program
Check” for this program:
Do not check the above highlighted
checkbox (“Also display hidden messages in source code”). Click on
“Perform Check (F8)”.
We have 2 items listed in the report.
You can observe the comment here “Can be hidden using pragma ##NEEDED”.
Let us include the Pragma in our
Please note that Pragmas have to be
part of program code. You might observe that the Pragma ##NEEDED is included
before the end of the statement (before the period ‘.’ Symbol). Pseudo
Comments were actually comments and we would put them after the ‘.’ Or
Activate the program and rerun the
Extended Program Check (EPC).
This time we have zero errors.
Now let us rerun the EPC check by
checking the checkbox “Also display hidden messages in source code”:
Here is the EPC report:
The list of available Pragmas (or the
replacements for Pseudo Comments) can be obtained by executing the report
Please send us your feedback/suggestions at webmaster@SAPTechnical.COM
©2006-2007 SAPTechnical.COM. All rights reserved.
product names are trademarks of their respective companies. SAPTechnical.COM
is in no way affiliated with SAP AG.
Graphic Design by Round the Bend Wizards