Skip to Content
Author's profile photo Sudhir Lenka

Applying multiple filters on a complex table at the same time.

Hi All,

We came across a such scenario in our project. After doing a lots of exploration we found the solution, So thought of to share with you all.

Problem Statement: – Sometimes we come across a scenario where we need to apply multiple filters at the same time on a complex table.

Scenario: – Suppose we have a complex table ZCTEmployee with the following structure.

                    Employee Structure.PNG

                   

                  Let’s say we have a requirement to display the employees in a drop down on a Transaction screen, who matches a certain criteria.

                 E.g. The employees need to be populated in the drop-down, who belongs to X department and with grade A.

Assumptions: –

      1. The complex table ZCTEmployee is already created and required Java and ABAP codes are in place for the complex table.
      2. The transaction screen is ready with three UI elements.
        1. Grade-string
        2. Department-string
        3. Employee- Complex Table Drop Down

Solution:-

      1. We need to create 4 indexes for the complex table ZCTEmployee.
        1. EmpIDIndex(Unique)
        2. DepartmentIndex
        3. GradeByDepartmentIndex
        4. NameByGradeByDepartmentIndex
    • Please make sure the field and parent index are mapped properly as per the below screen shot.

                    CT-Index.PNG

                    2.  Make sure the transaction screen is designed as below and corresponding transaction is bound properly.


                             Screen.PNG

                    3.      Now our main intent is to pass the Grade & Department screen field values to the index of the complex table through cascade parent.

                                   CT-Field.PNG

                   4.     Now we will write a rule to pass both the screen field values(Grade & Department) to the index of the complex table, which is very interesting.

                             Rule-x.PNG

        • Here NEWLINE plays a major role.

Conclusion :- NEWLINE allows to return more than one value from a rule.


I hope this article will helpful.

Have a nice day!!


Thanks,

Sudhir.

  


Assigned Tags

      4 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Manish Kumar
      Manish Kumar

      wow, this is really very helpful article to achieve multiple filter on Complex table in Agentry

      Author's profile photo AK K
      AK K

      Found this really helpful.... thanks keep posting

      Author's profile photo Former Member
      Former Member

      This is really useful information. I can see lot of business use for this functionality.

      Good one!

      Author's profile photo Former Member
      Former Member

      Very helpful. 🙂