Skip to Content
avatar image
Former Member

syntax problem

Hi All!

I want the equivalent ABAp syntax code for this selection screen code:

DELETE et_vekp WHERE NOT ( packvorschr IN selpackv

AND status IN selstat

AND vpobj IN selvpobj).

The inputs for selstat selpackv and selvpobj is coming from selection screen.

I had done like this : I had passed fixed inputs through r_packins r_vpobj and r_status (ranges)

DELETE et_vekp WHERE NOT ( packvorschr in r_packins

AND status in r_status

AND vpobj in r_vpobj ).

in first code : if suppose packvorschr is blank in selection screen the output is a combination of all packvorschr satisfying the condition of status and vpobj.all packvorschr is selected

But for the second code the output is values where packvorschr is blank

0r null.I mean its not taking all packvorschr into consideration and only null values are pulled out with the combination of other conditions.

I want the second code to work similarly like the first one.Please advise changes.

Regards

Praneeth

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

5 Answers

  • Best Answer
    avatar image
    Former Member
    May 26, 2006 at 10:26 AM

    Hi Praneeth,

    can u show ur code for populating r_packins r_vpobj and r_status .

    have u filled like this

    r_pacins-sign   = 'I'.
    r_pacins-option = 'EQ'.
    r_pacins-low    = 'XXXX'.
    r_pacins-high   = 'XXXX'.
    appen r_packins.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi chandra sekhar!

      I had passed the same values as you said.The problem is i am dynamically pessing the packvorschr and some times it may contain values and some times it may be blank.

      Regards

      Praneeth

  • avatar image
    Former Member
    May 26, 2006 at 10:34 AM

    Hi Praneeth,

    See that all ranges variable refer to same

    table fields as your Select-options.

    For eg. s_matnr for mara-matnr.

    r_matnr for mara-matnr.

    Regards,

    Amole

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    May 26, 2006 at 10:26 AM

    are u append the value in range....

    Add comment
    10|10000 characters needed characters exceeded

  • May 26, 2006 at 10:58 AM

    If in the selection screen selpackv

    is not filled with any values, then it is <b>NOT</b> equivalent to

    r_packins-low = space.

    r_packins-high = space.

    r_packins-sign = 'I'.

    r_packins-option = 'EQ'.

    NO values in selpackv means => No Values in r_packins.(Do not fill r_packins at all in tis case).

    Regards,

    Ravi

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    May 26, 2006 at 11:09 AM

    Hi ,

    As you are dynamically populating ranges

    table it will be better you follow below

    logic.

    if not packvorschr is initial.

    build r_packins table

    endif.

    if not status is initial.

    build r_status table

    endif.

    Please paste your code where you are populting

    ranges dynamically. Debug carefully you will

    know the problem yourself.

    Regards,

    Amole

    Add comment
    10|10000 characters needed characters exceeded