Use these instructions to build a UMF_QUERY input document
to find a specific entity in the entity database. You send the UMF_QUERY
input document through Web services into a Web services pipeline for
processing. After the pipeline processes the query, Web services returns
a UMF_QUERY_RESULT output document that contains the details about
the requested input entity.
Before you begin
The embedded WebSphere Application Server must
be running, and at least one Web services pipeline must be started
and running to receive and process the UMF_QUERY input document.
About this task
Because the search request is a UMF input document, the criteria
must be formatted using valid UMF tags. You can use any text editor
or utility that creates UMF.
Procedure
- Create a new UMF_QUERY input document.
- In the ROOT segment, enter the required UMF tags and values:
- Enter the data source code in the DSRC_CODE tag. The
default data source code for Web services pipeline searches is 1589. If you use a different data source code than the default Web
services pipeline search data source code, make sure that it is configured
not to resolve entities.
- Enter the data source reference code that references
the requesting message transaction in the DSRC_REF tag. The
data source reference code should be meaningful, because it is returned
to the calling application.
- Enter the format code to indicate the output format
of the results using the FORMAT_CODE tag. The pipelines
come with three built-in format codes for a Web services pipeline
search using UMF_QUERY:
- WS_DETAIL, which returns all available entity data for the input
entity ID
- WS_RELATION, which returns a list of all entities related to the
input entity ID at a 1-degree relationship
- WS_ALERT query, which returns all role alerts in the system involving
the input entity ID
If you use a different format code, the format code must be configured
in the UMF_OUTPUT_FORMAT table.
- In the ENTITY_ID tag, enter the entity ID for the entity
you want to return information about.
- Enter any other query criteria using the other optional
UMF segments of <NAME>, <ADDRESS>, <EMAIL>, <ATTRIBUTE>,
and <NUMBER>.
- Send the UMF_QUERY input document to a Web services pipeline.
Results
A Web services pipeline ingests the UMF_QUERY document, using
the criteria specified to find entities in the database that match
the query. The pipeline then processes the query, creates normal logging
files, and returns the results in a UMF_QUERY_RESULT output document
through Web services to the calling application.
Example UMF_QUERY search
This example UMF_QUERY
searches for all information about entity ID 1223:
Note: This example
is formatted for readability and does not follow the required one
line per UMF record format.
<UMF_QUERY>
<DSRC_CODE>1589</DSRC_CODE>
<DSRC_REF>546</DSRC_REF>
<FORMAT_CODE>WS_DETAIL</FORMAT_CODE>
<ENTITY_ID>1223</ENTITY_ID>
</UMF_QUERY>