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

Validate plant and material on selection screen with select-options

Hi all,

I want to validate plant and material on selection screen. More over I need to validate the combination of that also (i.e plant based materials). Individually I made the validations, but combination I didn’t get it.

For your information both are select-options, please reply me if you have an idea. The table to get the relationship is KEKO. <b>I have the below code for parameters, but I require code for select options.</b>

SELECT MATNR WERKS FROM KEKO UP TO 1 ROWS 
INTO (KEKO-MATNR, KEKO-WERKS)
WHERE MATNR = P_MATNR AND 
WERKS = P_WERKS.
IF SY-SUBRC <> 0.
MESSAGE E023 WITH 'COST ESTIMATE NOT FOUND FOR '
P_MATNR P_WERKS 'COMBINATION'.
ENDIF.
ENDSELECT.

Surely I will reward you.

Thanks in Advance,

Raghu.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Nov 23, 2007 at 12:09 PM

    Hi Raghu

    Create ranges for the parameter

    and append lines of p_xxx to r_xxx

    now in the select query under where condt give the range dec ie r_xxxx

    hope this help u

    Reward pts if useful

    Regards

    Sreenivas

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Raghu,

      You can't validate on select-options, MARC will have N to 1 relation between Material and plant.

      You can do one thing, keep material as select-option and plant as parameter, now you can validate the materials on plant level.

      Reward if this helps,

      Satish

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.