Skip to Content
avatar image
Former Member

Difference 1st and 2nd global declaration in the start routine of a transfo

Hi Folkds,

What is the difference between first and second global declaration in the start routine of a transformation?

First: $$ begin of global - insert your declaration only below this line -

Second: $$ begin of 2nd part global - insert your code only below this line *

I browse a lot of forum post but got no clear definition. Bellow definition from one post seemd to be the most approriated, but as there where several other onces I wanted to re-check if somebody can confirm bellow:

-


There are two places where you can make a global declaration in a Start or End Routine.

1. $$ begin of global - insert your declaration only below this line -

... "insert your code here

*" In this part your global declarations values will only be retained for the 1st packet. For e.g. if here you are reading any date range from a Ztable, then it will applt only for the first data packet

.*2. $$ begin of 2nd part global - insert your code only below this line *

... "insert your code here

$$ end of 2nd part global - insert your code only before this line *

" You need to declare here in a scenario where data volume is large and you need to retain the values across the whole data set comprising of multiple packets. (As e.g I cited above)

-


Some difference I noted is that 1st part never acceptes an include. But 2nd part does.

Thanks for all replies in advance,

Axel

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Jan 20, 2011 at 01:56 PM

    >

    >

    > 1. $$ begin of global - insert your declaration only below this line -

    > ... "insert your code here

    >

    > *" In this part your global declarations values will only be retained for the 1st packet. For e.g. if here you are reading any date range from a Ztable, then it will applt only for the first data packet

    > l

    not true

    1st part => declarations according to OO standards

    2nd part => declarations according to "normal" ABAP standards

    the official docu is rather "vague"

    (http://help.sap.com/saphelp_nw70ehp2/helpdata/en/43/857adf7d452679e10000000a1553f7/content.htm)

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Mario Tibollo

      apparently I once double checked this with SAP, this was their answer

      In the first global part you can write your declaration or code you want to be able to reach globally in the tranformation.

      The 2nd global part will be used for those transformations which are migrated from an update or transfer rule. Routines used there will be automaticaly generated into the 2nd global part.

  • avatar image
    Former Member
    Jan 18, 2011 at 12:33 PM

    Anyone?

    Add comment
    10|10000 characters needed characters exceeded

  • Jul 28, 2014 at 05:57 PM

    This message was moderated.

    Add comment
    10|10000 characters needed characters exceeded