IBM Support

TECH : Inserting/Modifying hang-off table records via base APIs and Audit behavior regarding the same

Troubleshooting


Problem

TECH : Inserting/Modifying hang-off table records via base APIs and Audit behavior regarding the same

Symptom

Inserting/Modifying hang-off table records via base APIs and Audit behavior regarding the same:

Cause

Resolving The Problem

Let us approach it by considering the hang-off table EXTN_ABC which has the parent YFS_ORDER_HEADER. Assuming that AUDITREQUIRED is N in the extensions.xml for this hang-off table.

If we want to insert records in the hang-off table while the order is created i.e while createOrder API is invoked then we can pass the below XML to the createOrder API:
<Order BuyerOrganizationCode="" EnterpriseCode="DEFAULT" OrderName="ConfirmAssgn-3" OrderNo="abc-2007" SellerOrganizationCode="DEFAULT" ReqDeliveryDate="2006-10-17" ReqShipDate="2006-10-09" OrderHeaderKey="abc1111" >

<OrderLines>
<OrderLine OrderedQty="1" ReservationMandatory="N" ShipNode="NODE" >
<Item ItemID="Watch" ProductClass="A" Quantity="1"/>
<PersonInfoShipTo AddressLine1="aaa" ...../>
<PersonInfoMarkFor AddressLine1="bb" ..... />
</OrderLine>
</OrderLines>
<PersonInfoShipTo AddressLine1="ggg" ......... />
.........................
........................
<Extn>
<EXTNABCList>
<EXTNABC AvailableDate=" " Createprogid=" "
Message=" " Modifyprogid=" " Modifyts=" "
Modifyuserid=" " OrderHeaderKey="abc1111" OrderLineKey=" "
RequestType=" " RetryCounter=" " SerialNumber=" "
ShipmentKey=" " Status=" ">

<YFSOrderHeader BuyerOrganizationCode=" "
OrderNo=" " SellerOrganizationCode=" "
ShipNode=" " ShipToID=" " ShipToKey=" " >
</YFSOrderHeader>
</EXTNABC>
</EXTNABCList>
</Extn>
</Order>

In the above XML we can see that hang-off table attributes are present under EXTN element. After the XML is passed to the createOrder API, we can see that corresponding records are inserted in the Order related tables as well as the EXTN_ABC table.

Similarly, if we want to make any changes to the values in EXTN_ABC table, we can do it by passing relevant XML to changeOrder API :

<Order Action="MODIFY" OrderHeaderKey="abc1111" >
<Extn>

<EXTNABCList>
<EXTNABC SerialNumber="1111">

<YFSOrderHeader OrderHeaderKey="abc1111" >
</YFSOrderHeader>
</EXTNItemActivation>
</EXTNABCList>
</Extn>
</Order>

At the Order level, we pass the Order Header Key for reference. At the EXTN level, we pass the value that we want to modify. Here we are trying to modify the earlier Serial_Number to a new value i.e. 1111.

Assume in the extensions.xml, under Audit References for EXTN_ABC, Serial_Number is also referenced. In that case while we modify the serial_number from the changeOrder API, corresponding audit records will be inserted in the yfs_order_audit and yfs_order_audit_detail table irrespective whether AuditRequired is Y or N. This is because EXTN_ABC is order related hang-off table.

If the hang-off table is not order related, then audits will be recorded in yfs_audit table if AuditRequired field is Y else not.


Refer Customization Guide (Chapter : 7.2.6 : Creating Custom and Hang-Off tables) and Solution #20255 (Inserting/Modifying records in the hang-off table via Hang-off services and Audit behavior regarding the same ).

[{"Product":{"code":"SS6PEW","label":"IBM Sterling Order Management"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Component":"Not Applicable","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]

Historical Number

PRI49801

Product Synonym

[<p><b>]Fact[</b><p>];

Document Information

Modified date:
16 June 2018

UID

swg21530964