Skip to Content

Michal’s PI tips: How to use User Defined Message Search from external applications in PI 7.3 ?

It turnes out that sometimes we need to be able to not only use User Defined Message Search in PI to find related messages on the basis of their content but also to be able to use this functionality outside of our PI system. How can we achive that? We have a standard web service which allows to get the message data on the basis of the message ID as per my article:  PI/XI: how to get a PI message from java stack (AAE) in PI 7.11 from ABAP? but how to get the message ID on the basis of the User Defined Message Search ? We can also do this by creating a simple “select” web service on our PI system. The flow can look like this:

Sync WS (with SOAP adapter) <- ->  PI  <- -> JDBC  (to call PI’s DB)

Step 1

Create a User Defined Message Search configuration as per my article:

PI/XI: Selecting messages using the content of the message in SAP PI 7.3 – teaser

Step 2

I named the search criteria – KRAW – as shown in Figure below.


You can easily check that the extractor for search criteria – KRAW exists in table – XI_AF_LMS_EXTRACTOR as shown in the figure below.


Step 3

Now the fun part – on the basis of the extractor’s name (KRAW) and the User Defined Message Search’s value (in our case – “Michal Krawczyk”) we can get the message ID from table XI_AF_LMS_DATA and we can use the message ID to get the content of the message as per my article metioned at the beginning of this blog.


Further notes:

If we need we may also use another table: XI_AF_LMS_FILTER to check that the filter was created from our configuration:


Hopefully soon we will get a web service from SAP which will have the same functionality but in the meantime we can create our own on the basis of the tables metioned here.

You must be Logged on to comment or reply to a post.
  • Hi Michal,

    Assuming you're using the SFTP adapter to get all xml files setting it as * to. How can you define a filter on it's filename? Other filters I have are working except for filename (which i want to include as well).

    I have defined it as:

    Nothing was populated. Not sure if this approach is feasible.



  • Hi all,

    Could anyone please elaborate where in PI server can we find the above mentioned tables XI_AF_LMS_EXTRACTOR, XI_AF_LMS_DATA & XI_AF_LMS_FILTER.

    I am new to PI single stack & hence having trouble in getting accustomed.

    Appreciate your kind response.



    • Hi Former Member,

      Did you find how to access the table, I am looking for similar information. Please let me know if you have got some leads.