11-23-2007 12:06 PM
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 didnt 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.
11-23-2007 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
11-23-2007 12:21 PM
Hi..
Thanks for the reply.
But in this case i have select-options, not parameters.
So please help me in case of select-options.
reagards,
raghu.
11-23-2007 12:26 PM
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