Troubleshooting
Problem
There is an extended database attribute 'ExtnDepartmentDesc' on the YFS_SHIPMENT_LINE table. Using getShipmentList API the value of this extended attribute need to be retrieved via a complex query.
Symptom
Consider the following sample input xmls for adding complex queries to the getShipmentLineList API.
Complex query 1:
Input xml:
<Shipment AssignedToUserId="user1" StatusQryType="FLIKE" Status="1100.70.06.20" DeliveryMethod="SHP" SCAC="" SCACQryType="EQ">
<ShipmentLines>
<ShipmentLine>
<Extn>
<ComplexQuery Operator="AND">
<Or>
<Exp Name="Extn_ExtnDepartmentDesc" ExtnDepartmentDescQryType="EQ" Value="TENTS" />
<Exp Name="Extn_ExtnDepartmentDesc" ExtnDepartmentDescQryType="EQ" Value="GARAGE" />
</Or>
</ComplexQuery>
</Extn>
</ShipmentLine>
</ShipmentLines>
</Shipment>
<ShipmentLines>
<ShipmentLine>
<Extn>
<ComplexQuery Operator="AND">
<Or>
<Exp Name="Extn_ExtnDepartmentDesc" ExtnDepartmentDescQryType="EQ" Value="TENTS" />
<Exp Name="Extn_ExtnDepartmentDesc" ExtnDepartmentDescQryType="EQ" Value="GARAGE" />
</Or>
</ComplexQuery>
</Extn>
</ShipmentLine>
</ShipmentLines>
</Shipment>
Complex query 2:
Input xml:
<Shipment AssignedToUserId="user1" StatusQryType="FLIKE" Status="1100.70.06.20" DeliveryMethod="PICK" SCAC="" SCACQryType="EQ"><ShipmentLines>
<ShipmentLine>
<Extn>
<ComplexQuery Operator="AND">
<And>
<Or>
<Exp Name="Extn_ExtnDepartmentDesc" QryType="EQ" Value="GARAGE" />
<Exp Name="Extn_ExtnDepartmentDesc" QryType="EQ" Value="TENT" />
</Or>
</And>
</ComplexQuery>
</Extn>
</ShipmentLine>
</ShipmentLines>
</Shipment>
Cause
The getShipmentLineList API input should contain below details. Use only 'ShipmentKey' in the getShipmentList API input.
A complex query cannot be placed under Extn Attributes. The 'name' attribute of the Exp node should be prefixed with 'Extn_' for extended database columns (e.g., ExtnDepartmentDesc should be Extn_ExtnDepartmentDesc in the Expression).
Environment
IBM Sterling Order Management System Software v10
Resolving The Problem
Step 1: Invoke the 'getShipmentLineList' API
Input xml :
<ShipmentLine>
<ComplexQuery Operator="AND">
<Or>
<Exp Name="Extn_ExtnDepartmentDesc" ExtnDepartmentDescQryType="EQ" Value="PEN" />
<Exp Name="Extn_ExtnDepartmentDesc" ExtnDepartmentDescQryType="EQ" Value="DEN"/>
</Or>
</ComplexQuery>
</ShipmentLine>
Step 2: Invoke the 'getShipmentList' API
Once the necessary data is retrieved from the previous API call, proceed to use the 'getShipmentList' API. The input for this API should contain all the shipment keys obtained from the output of the previous API.
Input xml :
<Shipment AssignedToUserId="user1" StatusQryType="FLIKE" Status="1100.70.06.20" DeliveryMethod="SHP">
<ComplexQuery Operator="AND">
<Or>
<Exp Name="ShipmentKey" Value="value1" />
<Exp Name="ShipmentKey" Value="value2"/>
<!-- ... Add more shipment keys as needed ... -->
<Exp Name="ShipmentKey" Value="valueN"/>
</Or>
</ComplexQuery>
</Shipment>
<ComplexQuery Operator="AND">
<Or>
<Exp Name="ShipmentKey" Value="value1" />
<Exp Name="ShipmentKey" Value="value2"/>
<!-- ... Add more shipment keys as needed ... -->
<Exp Name="ShipmentKey" Value="valueN"/>
</Or>
</ComplexQuery>
</Shipment>
Related Information
Document Location
Worldwide
[{"Type":"MASTER","Line of Business":{"code":"LOB59","label":"Sustainability Software"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SS6PEW","label":"IBM Sterling Order Management"},"ARM Category":[{"code":"a8m0z000000cy00AAA","label":"Orders"}],"ARM Case Number":"TS013528981","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All Versions"}]
Was this topic helpful?
Document Information
Modified date:
06 June 2024
UID
ibm17116574