Skip to Content
avatar image
Former Member

enhance search

hi all,

i have a requirement to enhance the standard search functionality ( i am not using the advanced search , but the normal one) .

what i need is to extend the search criteria with one more option. for example i have a drop down in the search criteria and i can select one value as a search criteria. but i have to combine two drop down values and the search functionality should search for both these values. do i need to enhance the search query itself ?

as i said i am not using the advanced search but the normal one.

please help.

regards,

nikita.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Jun 27, 2010 at 12:06 PM

    Hi Nikita,

    I hope I got you correct.

    The reason why SAP introduced the AdvancedSearches is exactly the point you mention: With normal queries you can only have "SEARCH CRITERIA = VALUE". The AdvancedSearches allow you to have multiple values with different operators for a single search criteria. You can compare it to PARAMETERS and SELECT-OPTIONS statement in ABAP reports.

    The answer to your question is: No, you can not have multiple values for your search criteria in a normal search.

    The way to go, if for whatever reason you do not like AdvancedSearches, in my opinion is to enhance the search structure and the implementation class of the search.

    My suggestion would be to use a AdvancedSearch. This way you could supply select-option like your criteria. You would have to implement the search logic never the less.

    cheers Carsten

    Add comment
    10|10000 characters needed characters exceeded

    • Hi,

      If it is a normal search using CL_CRM_BOL_QUERY_SERVICE, you cannot repeat search parameters. So you can either use CL_CRM_BOL_DQUERY_SERVICE or as you already mentioned you can add a new parameter to the structure and add it to the configuration with same description. I would suggest using dquery service.

      Regards,

      Arun

      Edited by: Arun Kumar on Jun 29, 2010 10:41 AM

  • Jun 28, 2010 at 07:05 AM

    Hi,

    You can add the increment/decrement ( +/- buttons ) to your search criteria through coding, using bsp:bee tags. But it is a bit complex idea implemting this. You can use the existing advancesearchcriteria, if possible.

    1. Add increment/decrement buttons and assign onClick event handlers.

    2. When user clicks + (plus) button, create reference to htmlb:dropdownbox and assign it to bsp:bee tag reference. This should be done decrement button to remove the added search field.

    Regards,

    Arun

    Add comment
    10|10000 characters needed characters exceeded