Integration XML
Integration XML
Infosys
INFOSYS LIMITED
Bangalore
Date:
COPYRIGHT NOTICE
©2014 Infosys Limited, Bangalore, India. All rights reserved. Infosys believes the information
in this document is accurate as of its publication date; such information is subject to change
without notice. Infosys acknowledges the proprietary rights of other companies to the
trademarks, product names and such other intellectual property rights mentioned in this
document. Except as expressly permitted, neither this document nor any part of it may be
reproduced, stored in a retrieval system, or transmitted in any form or by any means,
electronic, mechanical, printing, photocopying, recording or otherwise, without the prior
permission of Infosys Limited and/or any named intellectual property rights holders under
this document.
Infosys Limited
Hosur Road
Electronic City, 3rd Cross
Bangalore 560 100
India.
Telephone: (91) (80)28520 261-270
Fax: (91) (80) 8520 362
Website: http://www.infosys.com
Project Details
H/W Platform : NA
S/W Environment : NA
Target readers
All
Keywords
Prerequisite
PL / Sql
Table of Contents
1.0 Introduction
Integration saved queries provide necessary control and flexibility to identifying and search
information without using a GID or when you want to generate a GID based on a query.
Within OTM Integration Saved queries can be accessed from Business Process Automation
> Power Data > Integration > Integration Saved Queries.
Please find the sample Incoming XML and how the integration saved query is used to populate
the GID given below
<TransmissionBody>
<GLogXMLElement>
<ShipmentStatus>
<ServiceProviderAlias>
<ServiceProviderAliasQualifierGid>
<Gid>
<Xid>GLOG</Xid>
</Gid>
</ServiceProviderAliasQualifierGid>
<ServiceProviderAliasValue>SAMPLE.EXAMPLE</ServiceProviderAliasValue>
</ServiceProviderAlias>
<Gid>
<DomainName>SAMPLE/EXAMPLE</DomainName>
<Value>11111</Value>
</Gid>
Sample Incoming XML with changes made to accommodate an Integration Saved Query
Changes
<TransmissionBody>
<GLogXMLElement>
<ShipmentStatus>
<ServiceProviderAlias>
<ServiceProviderAliasQualifierGid>
<Gid>
<Xid>GLOG</Xid>
</Gid>
</ServiceProviderAliasQualifierGid>
<ServiceProviderAliasValue>SAMPLE.EXAMPLE</ServiceProviderAliasValue>
</ServiceProviderAlias>
<IntSavedQuery>
<IntSavedQueryGid>
<Gid>
<DomainName>SAMPLE/TEST1</DomainName>
<Xid>GET_SHIPMENT_GID</Xid>
</Gid>
</IntSavedQueryGid>
<IntSavedQueryArg>
<ArgName>INPUTVALUE</ArgName>
<ArgValue>123456</ArgValue>
</IntSavedQueryArg>
</IntSavedQuery>
How it works
As soon as the XML comes in the “Get_Shipment_Gid” integration saved query is called before
populating the GID. The query within this integration saved query is executed to populated
the GID value within ArgValue
There are different ways you can write sql within Integration Saved Queries.
Please find some Sample Integration Saved Query calls given below
UNION
UNION
SELECT GET_SHIPMENT_GID
('{%SHIPMENTID%}','{%ORDERID%}','{%POID%}','{%CARRIERPRO%}') FROM
DUAL
Please note that the GET_SHIPMENT_GID is a procedure call that you are making and it
needs to be used in conjunction within a union as indicated above
It is a common requirement that you might have to populate GID based on multiple
arguments within an XML. However, handling such requirement becomes tricky as you need
to make changes to the XML to hold multiple arguments
Please find a sample XML where you have to populate the Shipment GID based on multiple
arguments ie., either Shipment XID or Order Release GID or PO ID
<TransmissionBody>
<GLogXMLElement>
<ShipmentStatus>
<ServiceProviderAlias>
<ServiceProviderAliasQualifierGid>
<Gid>
<Xid>GLOG</Xid>
</Gid>
</ServiceProviderAliasQualifierGid>
<ServiceProviderAliasValue>SAMPLE.TEST1</ServiceProviderAliasValue>
</ServiceProviderAlias>
<IntSavedQuery>
<IntSavedQueryGid>
<Gid>
<DomainName> SAMPLE </DomainName>
<Xid>GET_SHIPMENT_GID</Xid>
</Gid>
</IntSavedQueryGid>
<IntSavedQueryArg>
<ArgName>SHIPMENTID</ArgName>
<ArgValue>123456</ArgValue>
</IntSavedQueryArg>
<IntSavedQueryArg>
<ArgName>ORDERID</ArgName>
<ArgValue>1234</ArgValue>
</IntSavedQueryArg>
<IntSavedQueryArg>
<ArgName>POID</ArgName>
<ArgValue>123456</ArgValue>
</IntSavedQueryArg>
<IntSavedQueryArg>
</IntSavedQueryArg>
</IntSavedQuery>
Sample integration saved query to handle multiple argument value to populate the Shipment
GID
UNION ALL
SELECT GET_SHIPMENT_GID
('{%SHIPMENTID%}','{%ORDERID%}','{%POID%}','{%CARRIERPRO%}') FROM
DUAL
Please find the list of public OTM saved queries within OTM given below
Domain
Saved Query Name Name
INT_INVOICE_GID_EXAMPLE_1 PUBLIC
INT_INVOICE_GID_EXAMPLE_2 PUBLIC
INT_LOCATION_GID_1 PUBLIC
INT_LOCATION_GID_2 PUBLIC
INT_SHIPMENT_GID_1 PUBLIC
INT_SHIPMENT_GID_2 PUBLIC
INT_SHIPMENT_GROUP_STATUS_GID_1 PUBLIC
INT_SHIPMENT_GROUP_STATUS_GID_2 PUBLIC
INT_SHIPMENT_STATUS_GID_1 PUBLIC
INT_SHIPMENT_STATUS_GID_2 PUBLIC
INT_S_SHIP_UNIT_GID_EXAMPLE_1 PUBLIC
INT_S_SHIP_UNIT_GID_EXAMPLE_2 PUBLIC
INT_TRANS_ORDER_GID_1 PUBLIC
INT_TRANS_ORDER_GID_2 PUBLIC
INT_TRANS_ORDER_LINE_GID_1 PUBLIC
INT_TRANS_ORDER_LINE_GID_2 PUBLIC
S_EQUIPMENT_1 PUBLIC
6.0 P.S
7.0 Reference