Friday 11 October 2019

Custom Search help Find technical information, Debug and Troubleshoot search help not returning any values

This blog discusses how you could add SAP custom Search help to standard search help and also troubleshoot why the SAP custom search help does not return any values even when user selected multiple values. It covers below topic areas:

i. Check how to find the technical name of the search help being used
ii. Add custom search help by modifying the standard search help
iii. Fix the issue for user being able to see any option returned when selecting multiple options in the search help window.

Find technical information to add custom search help


Find the technical information for the specific search help by clicking F1. Below shows the Search help for CJI3 transaction and find the table name as V_PRSMP

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Using “where-used” find the specific search help that uses the table

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Below is the search help which uses that view.

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Check PRSMP search help and find that it is an elementary search help. So, check if there is any other search help linked to it. Found the search help PRSM using “where used”

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Below screen shows PRSMP is linked to PRSM search help.

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

The search help PRSM is a collective search help.You can find the corresponding user exit in which the breakpoint can be set to understand how it works or check on the individual search help in the ‘Included search helps’ option.

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Add custom search help to standard.


Created a custom search help as below with the selection method as a view which fetches the result

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

This view has a join with table PROJ

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

There can be other kinds of search help you could create. Below shows another example of a search help having selection method and search help exit.

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

For this requirement an elementary search help as my custom code and added it in the collective search help “Included search help” Section as below.

After debugging there seems to be some parameter missing which caused the issue of not being able to populate the value from the search help. Read more on the section below

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Reported issue:


Multi-selection search help did not return any values.

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Using Multiple selection button user needs to populate more than 1 WBS elements

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Custom search help was created as seen below

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

User can choose to select multiple options as seen below and click on green button to proceed ahead.

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

There was no value returned

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

Fix search help not returning result issue:


To start debugging popup since you cannot type /h to debug just drop the file on the GUI for the specific screen which has pop up and you would open up the debug screen

[FUNCTION]

Command=/H

Title=Debugger

Type=SystemCommand

Found in debugging a parameter missing which caused the issue. There was a missing assignment of the elementary search help to the collective search help. Assign button was clicked and then copy this helped to fix the issue and the selection of the search help was returned back on the display screen.

SAP ABAP Development, SAP ABAP Tutorials and Materials, SAP ABAP Guides, SAP ABAP Online Exam

To summarize:


◈ This is how you could identify technical components related to SAP search help and to add custom search help to SAP standard.

◈ Understand  Elementary and Collective search help.

◈ Some tips on how you could debug pop-ups in SAP.

◈ Troubleshooting an issue we faced.

1 comment:

  1. Great Blog! Thank you so much for sharing knowledge about Sap Courses. This is useful information.
    SAP Courses London

    ReplyDelete