cancel
Showing results for 
Search instead for 
Did you mean: 

Retrieve search Criteria from Search iView

Former Member
0 Kudos

Hi ,

I need to capture the Search Criteria in my MDM Detail iView.

This is exactly similar to the requirement in this thread :

https://forums.sdn.sap.com/thread.jspa?messageID=5990916

I have done all the steps which is mentioned in this thread, however, I am still facing a problem.

I notice that in the above thread, Vinay gets FieldIds and TableIds in his search result where as I get the name of Field and the Table name in my search result.

search = MDM_PRODUCTS,1,1,2,MDM_PRODUCTS,false,2,MDM_PRODUCT_NUMBER,1,2,10000,1,0,Product_Status,0,0,0,0,0,0,0,0,0,false,0,

I have created a resultset iView where I have defined a custom event :

MySearch - EPCF - TableEvent

Target - updateSearch

Mapped Field - [MDM Search] - search (Parameter Name)

Parameter Format : standard

I am able to capture the search criteria, however when I try to deserialize it, I am facing a problem.


public void onActionhandleSearchEvent(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent, java.lang.String dataObject )
{
	String[] searchCriteria = dataObject.split("=");
	
	wdComponentAPI.getMessageManager().reportSuccess("Search = " + searchCriteria[1]);
	
	Search search = Search.deserialize(searchCriteria[1]);  // Line Number 170
}

If I comment the Search code, I get the output as following

MDM_PRODUCTS,1,1,2,MDM_PRODUCTS,false,2,MDM_PRODUCT_NUMBER,1,2,10000,1,0,Product_Status,0,0,0,0,0,0,0,0,0,false,0,

otherwise I get a dump :

java.util.NoSuchElementException

at java.util.StringTokenizer.nextToken(StringTokenizer.java:259)

at com.sap.mdm.search.Search.deserializeHelper(Search.java:234)

at com.sap.mdm.search.Search.deserialize(Search.java:213)

at com.cadence.SearchCompView.onActionhandleSearchEvent(SearchCompView.java:170)

at com.cadence.wdp.InternalSearchCompView.wdInvokeEventHandler(InternalSearchCompView.java:140)

... 45 more

What am I missing here ?

Regards,

Subramanian V.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

From the information you provide, it looks as if you are using MDM 5.5 SP6 Patch 2, but your iViews are generating a search from pre-patch 2. When installing MDM, did you also upgrade the portal content (packages BP_MDM_APPLICATION and BP_MDM_TECHNOLOGY)?

In any case, I recommend upgrading to SP6 Patch 3, the latest patch in the SAP Service Marketplace if this is not a problem for you.

Walter

Former Member
0 Kudos

Hi Walter,

Thank you very much for your answer. I will look into this and get back to you.

Regards,

Subramanian V.

Former Member
0 Kudos

Hi Walter,

I have upgraded the MDM Server to patch 3 and I am using JAVA API 5.5.63.60 and the program works beautifully.

Thank you once again for your prompt response.

Regards,

Subramanian V.

Answers (2)

Answers (2)

Former Member
0 Kudos

I'm using SP06 Patch 02 is there an equivalent for this Search.deserialize?

Thanks!

Former Member
0 Kudos

Hi,

What is your version of MDM?

Walter

Former Member
0 Kudos

MDM Server Build Version : 5.5.62.58

Regards,

Subramanian V.