Skip to Content
author's profile photo Former Member
Former Member

Error in Start routine

Hello Experts,

I am new to ABAP and am trying to create a start routine in the transformation from Info Cube1 to Info Cube2. My logic is to compare the ProductID(ZPROD) from Info Cube 1 to the Product ID in Data Store Object(ZDSO1). If this Product Id in the Cube1 is found in the DSO, then the record should be transferred to Info Cube2. I have written the following code but I am stuck up with too many errors. Please help me out

types: BEGIN OF TY_INT,

TY_INT TYPE /BIC/AZDSO100,

END OF TY_INT.

DATA: i_int type table of ty_int.

data: wa_dp type source_package.

Select * from /BIC/AZDSO100 into table i_int.

Loop at source_package into wa_dp.

if LOOP AT data_PACKAGE INTO wa_dp.</b>

IF zprod <> /BIC/AZDSO100

Delete source_package from wa_dp.

endloop.

Current error: Type "SOURCE_PACKAGE" is unknown

Thanks and Regards,

Laxmi

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Feb 05, 2012 at 08:24 AM

    i guess for declaration it should be data: wa_dp like line of source_package[].

    Edited by: AnshulR on Feb 5, 2012 9:24 AM

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Loop at source_package into wa_dp.

      if LOOP AT data_PACKAGE INTO wa_dp.

      IF zprod /BIC/AZDSO100

      Delete source_package from wa_dp.

      what is the purpose of above code..pls teel for what purpose you want above code.

      if you want to use nested loop, you can directly include loop in side loop

  • author's profile photo Former Member
    Former Member
    Posted on Feb 05, 2012 at 10:35 AM

    Hello Experts,

    >

    > I am new to ABAP and am trying to create a start routine in the transformation from Info Cube1 to Info Cube2. My logic is to compare the ProductID(ZPROD) from Info Cube 1 to the Product ID in Data Store Object(ZDSO1). If this Product Id in the Cube1 is found in the DSO, then the record should be transferred to Info Cube2. I have written the following code but I am stuck up with too many errors. Please help me out

    >

    > types: BEGIN OF TY_INT,

    > TY_INT TYPE /BIC/AZDSO100,

    > END OF TY_INT.

    > DATA: i_int type table of ty_int.

    > data: wa_dp type source_package.

    > Select * from /BIC/AZDSO100 into table i_int.

    > Loop at source_package into wa_dp.

    > if LOOP AT data_PACKAGE INTO wa_dp.</b>

    > IF zprod <> /BIC/AZDSO100

    > Delete source_package from wa_dp.

    > endloop.

    >

    > Current error: Type "SOURCE_PACKAGE" is unknown

    >

    > Thanks and Regards,

    > Laxmi

    Dear Laxmi, Please change the declaration statement as below.

    #1:

    data: ln_dp type _ty_s_SC_1,
    w_dp TYPE TABLE OF _ty_s_SC_1.

    #2:

    DATA: source_package_tmp1 TYPE _ty_t_sc_1.
               source_package_tmp1[] = SOURCE_PACKAGE[].

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.