‎2010 Oct 08 11:28 AM
Hi ,
I need to create a match code on field AUFNR of table AUFK. My requirement is that it should bring all AUFNR values where werks = 'AAAA' in AUFK and PLGRP = 'SU9' which is in AFKO table.
AFUK-aufnr = AFKO-AUFNR.
Kindly help
‎2010 Oct 08 1:29 PM
Hi ,
First create database view in SE11 for tables AUFK and AFKO
With Join
AUFK-MANDT and AFKO-MANDT
AUFK-aufnr and AFKO-AUFNR.
with selection conditions
werks = 'AAAA'
and
PLGRP = 'SU9'
Now create a searchhelp in SE11 for selection method as DATABASE view(created earlier) and assign the same to matchcode for AUFNR as below.
PARAMETERS augnr type aufk-aufnr MATCHCODE OBJECT Z_Z_AUF_MA.
Here Z_Z_AUF_MA is a search help.
If you want to use it in modulepool then you can assign search help(Z_Z_AUF_MA) to the input field
Please try it out, it works for me.
‎2010 Oct 19 9:22 AM