Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

what is matchcode objects and how can we create tthem

Former Member
0 Kudos
3,027

hai to all.

what is matchcode objects .

and how can we create matchcode objects

and how will it works

5 REPLIES 5

Former Member
0 Kudos
717

hi

match code is nothing but search help in se11.

u can use that in ur report for getting f4 help for ur ur parametr u declare in selection screen.

regard

karthik

Former Member
0 Kudos
717

Hi

In which version of SAP are you working?

Matchcodes are replaced by SEARCH HELPs in latest versions

see the doc

1) Elementary search helps describe a search path. The elementary search help must define where the data of the hit list should be read from (selection method), how the exchange of values between the screen template and selection method is implemented (interface of the search help) and how the online input help should be defined (online behavior of the search help).

2) Collective search helps combine several elementary search helps. A collective search help thus can offer several alternative search paths.

3)An elementary search help defines the standard flow of an input help.

4) A collective search help combines several elementary search helps. The user can thus choose one of several alternative search paths with a collective search help.

5)A collective search help comprises several elementary search helps. It combines all the search paths that are meaningful for a field.

6)Both elementary search helps and other search helps can be included in a collective search help. If other collective search helps are contained in a collective search help, they are expanded to the level of the elementary search helps when the input help is called.

CREATION:

Go to SE11 Tcode

select search help

give the 'z' search help name and create

select the selection method ur table name eg : 'mara'

dialog module 'display value immediately'.

add the field whatever u want and lpos = 1 and spos = 1 and check import and export parameter.

where left position when displaying and spos = search position

and then save and activate ..

See the links:

http://help.sap.com/saphelp_nw04/helpdata/en/cf/21ee38446011d189700000e8322d00/content.htm

http://help.sap.com/saphelp_nw04/helpdata/en/cf/21ee45446011d189700000e8322d00/content.htm

https://forums.sdn.sap.com/click.jspa?searchID=3173469&messageID=2176485

https://forums.sdn.sap.com/click.jspa?searchID=3173469&messageID=3601619

pls go through this for search help creation

http://help.sap.com/saphelp_nw2004s/helpdata/en/41/f6b237fec48c67e10000009b38f8cf/content.htm

http://help.sap.com/saphelp_nw04/helpdata/en/cf/21ee2b446011d189700000e8322d00/content.htm

Search Help Exits:

http://help.sap.com/saphelp_nw04/helpdata/en/cf/21ee52446011d189700000e8322d00/content.htm

http://www.sapdevelopment.co.uk/dictionary/shelp/shelp_exit.htm

https://forums.sdn.sap.com/click.jspa?searchID=4390517&messageID=1712818

Collective search help Combine several elementary search helps. A collective search help thus can offer several alternative search paths.

A Collective search help provides alternative search

Paths by combining elementary search helps.

Only one search help can be attached to a field, table or data element. Several search paths are therefore attached with a collective search help.

A collective search help also has interface parameters like

an elementary search help.

Like an elementary search help, a collective search help has an interface of IMPORT and EXPORT parameters with which the search help exchanges data. Using this interface, the collective search help can be attached to fields, tables and data elements exactly like an elementary search help.

Parameter assignment needs to be done for each of the

Included search helps.

When you define a collective search help, there are no components for describing the dialog behavior and data selection; instead the included search helps are listed here. You must assign the parameters of the collective search help to the interface parameters of the included search help for each inclusion.

User may choose the tab and thus the elementary

search maethod.

When we execute the search help SCUSTOM, we are confronted with a dialog which gives us an option of either restricting

By 1)Search for customer according to booking

2)Search for customer according to name.

These are effectively the elementary search helps (SCUSTOM_BOOK and SCUSTOM_NAME) which have been included in the collective search help SCUSTOM.

HOT KEY

The hot key is used to select the elementary search help from the collective search help and to enter the restrictions in the dialog box for restricting values directly from the entry field. If the user often searches for values using the same search help, this procedure can save time.

Steps to create a Collective Search Help

1)Enter the search help name and click on create.

2)Choose Collective search help radio button option as the search help type.

3)Enter the search help parameters.

4)Instead of the selection method, we enter the included

search helps for the collective search help.

5)We need to assign parameters for each of the included

search helps.

6)Complete the parameter assignment by clicking on the push button

7)Collective search help offers the user to obtain F4 help

using any of the included search helps.

Former Member
0 Kudos
717

Satya,

Match Code is nothing but a search help.

you can create one in se11 if its a report the declare like this in selection screen

p_id like zxxx-id obligatory matchcode object zmatch.

create a match code in se11 for vendor master say!!

if its dialog program

then in the attributes of the field under search help give zmatch

IF YOU WANT SEARCH HELP BASED ON MULTIPLE THING THEN YOU HAVE TO GO FOR COLLECTIVE SEARCH HELP WHERE YOU LIST ALL YOUR ELEMENTARY SEARCH HELPS

LIKE IN HERE

VENDOR BY COMANY,VENDOR BYCUSTOMER ETC ARE ELEMENTARY SEARCH HELPS

Vendor if you see the Search Help, it gives you the option for Vendor by Customer, Vendors by COmpany Code etc etc.

THEN YOU CREATE A COLLECTIVE SEARCH HELP WHERE YOU GIVE ALL YOUR ELEMTARY SEARCH HELP.

SI IF YOU WANT TO ADD TO THIS LIKE

Vendor by Customer, Vendors by COmpany Code ,VENDOR BY TAX NUMBER1

GO TO SELL CREATA ASEARCH HELP ZTEST

GIVE SOME SHORT DESC

THEN IN SELECTION METHOD GIVE THE TABLE I.E LFA1

THEN UNDER SEARCH HELP PARAMETER

GIVE

LIFNR SELECT IMPORT EXPORT LPOS 1 SPOS 1 AND PRESS ENTER

BELOW THAT

STCD1 LPOS2 SPOS 2 AND THEN PRESS ENTER

SAVE IT.

THEN FIND THE COLLECTIVE SEARCH FOR VENDOR FIELD AND JUST THIS TO IT.

<<<<reward points if useful>>>>>>

thanks.

Former Member
0 Kudos
717

Hi vani,

With help of match code we wil provide search help for field.

for example

selection-options:s_adrnr for kna1-adrnr.

for example for above field s_adrnr dont have serach help we have to provide serch help with match code.

i wil tel the procedure

first u have to create serch help in se11 ok.say that is <b>zserch </b>

now modify u r select options like this

<b>selection-options:s_adrnr for kna1-adrnr match code object zserch.</b>

Now u r field get serch help F4

Regards

kishore ale

asik_shameem
Active Contributor
0 Kudos
717

Hi,

match code is nothing but a search help ( F4 help ) for a particular field.

To create a match code,

Step1 : Go to Se11 and Select Search Help and Enter One Name and Click Create ( <b>zmatch_code</b> for example ).

Step2 : Enter your Table name in 'Selection Method' Field.

Step3 : Enter the field Name and tick the Flags Imp and Exp and Type 1 and 2 in Lpos,

Spos fields.

Step4 : Save and activate it and

In se38 Write the Code Like This,

parameters: p_name type char20 matchcode object <b>zmatch_code</b>

whenever u prees F4 on the field p_name. these values will get populated in the screen.