cancel
Showing results for 
Search instead for 
Did you mean: 

MDM 7.1 Java API Question - How to search a Lookup [Main] field

Former Member
0 Kudos

Hi

Scenario:

We have two main tables. The second one is linked to the first using the Lookup [Main] field. The relation between these tables is 1:N. Now if some search criteria for the first main table and some for the Lookup [Main] table is provided is there a way that we can do an AND search on both the tables at the same time so that we pull all the related matching records at one shot. Let me know if this is possible and if yes please provide some sample code sets as to how to create the search parameter.

Thanks,

KN.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

This requirement is achievable but not as you want. As per my understanding, there is an alternative to achieve this requirement that is explained below. Using MDM Java API You can achieve your requirement using some custom work.

As per your scenario, you are maintaining two main tables (e.g. Main_Table_A and Main_Table_B) and you want to fetch the data from both the table using some common search conditaions. As per the provided MDM Java functionalities, you cannot perform search on Lookup [Main Field].

To achieve it, you will have to maintain a common field in both the main tables e.g. Main_Table_A has fields a, b, c, d and Main_Table_B has a, e, f, g fields, where a is a common field in both the tables. As per my understanding your requirement is like this, you want to fetch the data of a, c, d, f, & g fields from Main_Table_A and Main_Table_B.

Steps:

1. Search the data from first main table on the basis of common fields and your desired search criteria and store it into a result-set object.

2. Search the data from second main table on the basis of common fields and your desired search criteria and store it into another result-set object.

3. Now, you can retrieve your selected fieldsu2019 data from these searched result-sets and display it on the portal. This is how you can achieve your requirement.

I know, this is little bit lengthy and tricky way but this is how you can achieve your requirement using MDM Java API.

Thanks/ -Tarun

Answers (4)

Answers (4)

Former Member
0 Kudos

Searched common fields in both tables to link the related records and show on UI.

Former Member
0 Kudos

Hi KN,

Did you get success in dig up any other alternative for your scenario or let me know if you tried the suggested solution?

Thanks/ -Tarun

Former Member
0 Kudos

Hi KN,

MDM does not support this functionality of searching MDM LookUp Main fields.

Regards,

Mandeep Saini

former_member205403
Active Contributor
0 Kudos

Hi,

I was going through MDM 7.1 Java API guide. On page no 77, I found statement that "Searching on Lookup Main fields is not supported." in the limitations section of Lookup Main Field. Based on this, I doubt if your requirement can be acheived.

Please check MDM 7.1 java API guide using [this link.|http://help.sap.com/saphelp_nwmdm71/helpdata/en/72/d36e1ed3ce43028adc851b8fed5668/MDM_Java_Net_API_Guide.pdf]

Also wait for some comments from experts.

Regards,

Shiv