Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Underscore declaration

former_member194669
Active Contributor
0 Kudos

While debugging one of the sap standard program i came across the following declaration


data: __seqta_tab type seqta occurs 01 with header line,
      __scope type ddenqscope,
      __wait type ddenqwait.
__wait = _wait.
__scope = _scope.

My question what is the significance of __ (2 underscore) & _ (1 underscore) declaration?

1 ACCEPTED SOLUTION

amit_khare
Active Contributor
0 Kudos

Its simply choice of individual developers for picking the naming conventions....

6 REPLIES 6

Former Member
0 Kudos

Hi

Nothing, just nothing.

I suppose some SAP AG developers like to assign a name starting with undercore to the program variable.

Perhaps there's a particular name convention....bu I don't believe it.

Max

0 Kudos

>

> Perhaps there's a particular name convention....bu I don't believe it.

>

> Max

Well, it appears to be particular to generated code for enqueue/dequeue FMs. It probably made the code generator a bit easier to build.

Rob

0 Kudos

Max,

Thanks for your quick reply.

I have seen this kind coding only in ENQUEUE & DEQUEUE fm's That where i got the above doubt.

amit_khare
Active Contributor
0 Kudos

Its simply choice of individual developers for picking the naming conventions....

naimesh_patel
Active Contributor
0 Kudos

Online Help suggest to have a Letter as the first character in the variable name..

Nameing Conventions and Namespaces

The following conventions apply for the names of all definable objects within ABAP programs, such as data types, data objects, classes, macros, or procedures:

The name must start with a letter. Only outside of ABAP objects can the name also start with a different character.

Regards,

Naimesh Patel

former_member194669
Active Contributor
0 Kudos

As this code coming out of system generated. i believe the __ & _ declaration don't have any significance.