This post is more of a note for myself, but it may also interest some of you out there. In this case, I am receiving purchase orders from my trading partner Commiskey_Inc. My OIC B2B Host configuration is as follows -
I regularly do OIC demos including B2B, using a very simple X12 P850 document -
GS*PO*Commiskey_IID*MyCompany_IID*20230314*1204*1027*X*004010~
ST*850*1027~
BEG*00*NE*8310138**20230314~
PO1*HOTD TShirt*30*EA*30~
PO1*HOTD Mug*1*EA*10~
PO1*HOTD Cap*5*EA*15~
CTT*3*985~
SE*8*1027~
GE*1*1027~
IEA*1*000000027~
Naturally, the B2B demo goes like a dream, but what do these fields mean?
ISA - Interchange Control Header - identifies the interchange -
ISA03 - Security Information Qualifier - '00' = No Security Information Present.
Net, net, ISA01 to ISA04 are hardly ever used.
ISA06 - Interchange Sender ID - this is my trading partner EDI Interchange ID, in my case, Commiskey_IID.
ISA07 - Interchange ID Qualifier, is a 2 char code, in my case ZZ.
ISA08 - Receiver Id, This identifies your partner's sender ID in outgoing messages. In my case this is MyCompany_IID.
ISA09 - Interchange Date - format is YYMMDD. My date is 23rd March 2023 so the value is 230314.
GS - Functional Group Header -
GS02 - Application Sender’s Code, sames as ISA06, so, in my example, Commiskey_IID.
GS03 - Receiver's Id, should be the same as ISA08, so, in my example, MyCompany_IID.
GS04 - Transaction Date - format CCYYMMDD, in my case, 20230314.
GS05 - Time in HHMM format.
ST segment - Transaction Set Header - first field is the Transaction Set Identifier Code, in my case 850 for purchase order. The second field is the Transaction Set Control Number - the control number that must be unique within the transaction set, in my case, 1027.
BEG segment -
Valid values include -
Valid values include -
- NE New Order
- NS New Store
- SA Standalone PO
- BK Blanket PO
Full list available here
BEG03 - Purchase Order Nr, with the value '8310138'. This field can be up to 22 chars.
BEG04 - optional
BEG05 - PurchaseOrderDate, with the value 20230314 (YYYYMMDD)
CUR - the Currency Segment -
Full list available here
CUR03 - Exchange Rate, in my case 1:1.
The next field is the quantity ordered, in my case, 30. The following field is Unit of Basis for Measurement Code for the quantity, e.g single item or case of items. So my first line is for 30 Hare of the Dog T-Shirts, each costing $30.
CTT - Transaction Totals - first field is he number of line items, in my case 3. The second field is the total order value, in my case - (30 * 30) + (1 * 10) + (5 * 15) = 985
SE - Transaction Set Trailer - indicates end of transaction set and contains a count of the transmitted segments (incl. ST and SE), in my case, 8. The second field is a unique Transaction Set Control Number (min 4 digits), in my case 1027.
GE - Functional Group trailer - First field contains the number of transaction sets included in the message, in my case, 1. Field 2 is Group Control Number, assigned by the sender.
IEA - Interchange Control Trailer - first field in the number of included functional included groups, in my case, 1. The second field, Interchange Control Number is a mandatory 9 digit number, in my case, 000000027.
A very helpful resource for me, when compiling this blog, was the EDI Academy Blog. Check it out here.
No comments:
Post a Comment