ABAP Geek 1 - ABAP program attributes

ABAP Geek 1 - ABAP program attributes

It is well documented that an ABAP program is more than just a piece of source code. Let's wrap up some facts.

In most programming languages, a program is merely a text written in a programming language that is compiled and linked into an executable file or that can be directly interpreted. In ABAP, a program consists of a text plus program attributes. You must maintain the program attributes, when you create a program or you can look up the program attributes for any existing program by choosing Goto--Attributes in the ABAP Editor.

Program Attributes

There are a lot of program attributes that are relevant for the program development. For example the program's Title that can be translated into another language, the program's Original language that steers the translation process for program texts, the Package of a program that steers its transportation and visibility, and so on.

But there are also program attributes that influence the execution of a program in the ABAP runtime environment. Those attributes affect the compiler, the semantics of ABAP statements, and the allowed contents of a program. Such important program attributes are:

Type

Each program has a program type. The program type defines, which building block a program might contain, how it can be executed, and if it supports screens.

Fixed point arithmetic

This attribute defines, whether for numerical data objects of data type p (packed numbers)

    Requires Free Membership to View

    When you register, you will start receiving targeted emails from my award-winning team of editorial writers. Our goal is to keep you informed on the hottest topics and biggest challenges faced by SAP professionals today.

    Hannah Smalltree, Editorial Director

    By submitting your registration information to SearchSAP.com you agree to receive email communications from TechTarget and TechTarget partners. We encourage you to read our Privacy Policy which contains important disclosures about how we collect and use your registration and other information. If you reside outside of the United States, by submitting this registration information you consent to having your personal data transferred to and processed in the United States. Your use of SearchSAP.com is governed by our Terms of Use. You may contact us at webmaster@TechTarget.com.

is the decimal point is relevant in calculations or assignments or if it is omitted. Normally, this attribute is always switched on and you might ask, why it can be switched off at all. Well, in very ancient times packed numbers had no real decimal point. It was taken into account only for presentation purposes. In order to stay downward compatible, for the introduction of fixed point arithmetic this switch was needed. In fact there are still programs that switch fixed point arithmetic off ¨C for example financial programs that calculate on the basis of cents instead of dollars.

Unicode checks active

This attribute defines, whether the stricter syntax and semantics rules that are needed in Unicode systems are applied to a program. In Unicode systems it is mandatory to switch it on. In non Unicode systems it is highly recommended to do so. Unicode programs are better programs. Many dangerous and error prone programming styles are not possible any more - for example, structures that contain numerical components are not treaded as one large character field any more but its fragment view is taken into account.

Horst Keller is a developer in the department 'NetWeaver Development Tools ABAP' of SAP.

Click here to read ABAP Geek 2 -- ABAP program types
This weblog originally appeared in the SAP Developer Network. To view original weblog click here.The SAP Developer Network is the central hub for the SAP technology community and is SAP's new collaborative community portal for developers, administrators and consultants. Registration to the SDN community at http://sdn.sap.com is free.

This was first published in November 2004

Join the conversationComment

Share
Comments

    Results

    Contribute to the conversation

    All fields are required. Comments will appear at the bottom of the article.

    Disclaimer: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.