**These specifications are a base model. All customers are responsible for ensuring their map or EDI is compliant with their trading partner's most current specifications.
X12 880 Grocery Products Invoice
X12 Release 4010Revised December 1, 2023
This Draft Standard for Trial Use contains the format and establishes the data contents of the Grocery Products Invoice Transaction Set (880) for use within the context of an Electronic Data Interchange (EDI) environment. This transaction set can be used to provide for customary and established grocery industry practice relative to billing details for finished goods in a retail or wholesale consumer market. The transaction set can be used by the supplier or broker organization to request payment from a retailer or wholesaler organization. This transaction set is to be used for standalone detail billing and cannot be used for statement billing or credit/debit adjustments.
Delimiters
~ Segment
* Element
> Component
EDI samples
None included
Interchange Control Header
RequiredMax use 1
To start and identify an interchange of zero or more functional groups and interchange-related control segments
Example
ISA*00* *00* *XX*XXXXXXXXXXXXXXX*XX*XXXXXXXXXXXXXXX*250328*1633*U*00401*000000000*X*X*>~
Authorization Information Qualifier
Required
Identifier (ID)
Code to identify the type of information in the Authorization Information
00
No Authorization Information Present (No Meaningful Information in I02)
Authorization Information
Required
String (AN)
Min 10Max 10
Information used for additional identification or authorization of the interchange sender or the data in the interchange; the type of information is set by the Authorization Information Qualifier (I01)
Security Information Qualifier
Required
Identifier (ID)
Code to identify the type of information in the Security Information
00
No Security Information Present (No Meaningful Information in I04)
Security Information
Required
String (AN)
Min 10Max 10
This is used for identifying the security information about the interchange sender or the data in the interchange; the type of information is set by the Security Information Qualifier (I03)
Interchange ID Qualifier
Required
Identifier (ID)
Min 2Max 2
Qualifier to designate the system/method of code structure used to designate the sender or receiver ID element being qualified
Codes
Interchange Sender ID
Required
String (AN)
Min 15Max 15
Identification code published by the sender for other parties to use as the receiver ID to route data to them; the sender always codes this value in the sender ID element
Interchange ID Qualifier
Required
Identifier (ID)
Min 2Max 2
Qualifier to designate the system/method of code structure used to designate the sender or receiver ID element being qualified
Codes
Interchange Receiver ID
Required
String (AN)
Min 15Max 15
Identification code published by the receiver of the data; When sending, it is used by the sender as their sending ID, thus other parties sending to them will use this as a receiving ID to route data to them
Interchange Date
Required
Date (DT)
YYMMDD format
Date of the interchange
Interchange Time
Required
Time (TM)
HHMM format
Time of the interchange
Interchange Control Standards Identifier
Required
Identifier (ID)
Code to identify the agency responsible for the control standard used by the message that is enclosed by the interchange header and trailer
U
U.S. EDI Community of ASC X12, TDCC, and UCS
Interchange Control Version Number
Required
Identifier (ID)
This version number covers the interchange control segments
00401
Draft Standards for Trial Use Approved for Publication by ASC X12 Procedures Review Board through October 1997
Interchange Control Number
Required
Numeric (N0)
Min 9Max 9
A control number assigned by the interchange sender
Acknowledgment Requested
Required
Identifier (ID)
Min 1Max 1
Code sent by the sender to request an interchange acknowledgment (TA1)
0
No Acknowledgment Requested
1
Interchange Acknowledgment Requested
Usage Indicator
Required
Identifier (ID)
Min 1Max 1
Code to indicate whether data enclosed by this interchange envelope is test, production or information
I
Information
P
Production Data
T
Test Data
Component Element Separator
Required
String (AN)
Min 1Max 1
Type is not applicable; the component element separator is a delimiter and not a data element; this field provides the delimiter used to separate component data elements within a composite data structure; this value must be different than the data element separator and the segment terminator
>
Component Element Separator
Functional Group Header
RequiredMax use 1
To indicate the beginning of a functional group and to provide control information
Example
GS*GP*XXXXXXX*XXX*20250328*1756*000*XX*004010UCS~
Functional Identifier Code
Required
Identifier (ID)
Code identifying a group of application related transaction sets
GP
Grocery Products Invoice (880)
Application Sender's Code
Required
String (AN)
Min 2Max 15
Code identifying party sending transmission; codes agreed to by trading partners
Application Receiver's Code
Required
String (AN)
Min 2Max 15
Code identifying party receiving transmission. Codes agreed to by trading partners
Date
Required
Date (DT)
CCYYMMDD format
Date expressed as CCYYMMDD
Time
Required
Time (TM)
HHMM, HHMMSS, HHMMSSD, or HHMMSSDD format
Time expressed in 24-hour clock time as follows: HHMM, or HHMMSS, or HHMMSSD, or HHMMSSDD, where H = hours (00-23), M = minutes (00-59), S = integer seconds (00-59) and DD = decimal seconds; decimal seconds are expressed as follows: D = tenths (0-9) and DD = hundredths (00-99)
Group Control Number
Required
Numeric (N0)
Min 1Max 9
Assigned number originated and maintained by the sender
Responsible Agency Code
Required
Identifier (ID)
Min 1Max 2
Code used in conjunction with Data Element 480 to identify the issuer of the standard
T
Transportation Data Coordinating Committee (TDCC)
X
Accredited Standards Committee X12
Version / Release / Industry Identifier Code
Required
String (AN)
Code indicating the version, release, subrelease, and industry identifier of the EDI standard being used, including the GS and GE segments; if code in DE455 in GS segment is X, then in DE 480 positions 1-3 are the version number; positions 4-6 are the release and subrelease, level of the version; and positions 7-12 are the industry or trade association identifiers (optionally assigned by user); if code in DE455 in GS segment is T, then other formats are allowed
004010UCS
Heading
010
Transaction Set Header
RequiredMax use 1
To indicate the start of a transaction set and to assign a control number
Example
ST*880*0001~
Transaction Set Identifier Code
Required
Identifier (ID)
Code uniquely identifying a Transaction Set
- The transaction set identifier (ST01) used by the translation routines of the interchange partners to select the appropriate transaction set definition (e.g., 810 selects the Invoice Transaction Set).
880
Grocery Products Invoice
Transaction Set Control Number
Required
Numeric (N)
Min 4Max 9
Identifying control number that must be unique within the transaction set functional group assigned by the originator for a transaction set
020
Invoice Identification
RequiredMax use 1
To transmit identifying dates and numbers for this transaction set
Usage notes
Example: G01200602129999920060201916048*00000001
Example
G01*20231202*XXXXXX*20231202*X*XXXXXX~
Date
Required
Date (DT)
CCYYMMDD format
Date expressed as CCYYMMDD
- G0101 is the invoice issue date.
Invoice Number
Required
String (AN)
Min 1Max 22
Identifying number assigned by issuer
Date
Optional
Date (DT)
CCYYMMDD format
Date expressed as CCYYMMDD
- G0103 is the date assigned by the purchaser to the purchase order.
Purchase Order Number
Required
String (AN)
Min 1Max 22
Identifying number for Purchase Order assigned by the orderer/purchaser
Usage notes
Mandatory - will not translate if not present.
Vendor Order Number
Optional
String (AN)
Min 1Max 22
Number assigned by a vendor referencing a particular customer purchase order
050
Date/Time
OptionalMax use 5
To specify pertinent dates and times
Usage notes
Example: G621120060210
Example
G62*03*20231202~
If either Date Qualifier (G62-01) or Date (G62-02) is present, then the other is required
Date Qualifier
Optional
Identifier (ID)
Code specifying type of date
02
Delivery Requested on this date.
03
Invoice Date
10
Requested Ship Date/Pick-up Date
11
Shipped on This Date
Date
Optional
Date (DT)
CCYYMMDD format
Date expressed as CCYYMMDD
060
Note/Special Instruction
OptionalMax use 20
To transmit information in a free-form format, if necessary, for comment or special instruction
Usage notes
Example:
NTEGENALL SALES SUBJECT TO SELLER STANDARD TERMS AND AGREEMENTS*
Example
NTE*ALL*XXXXX~
Note Reference Code
Optional
Identifier (ID)
Code identifying the functional area or purpose for which the note applies
ALL
All Documents
DEL
Delivery
GEN
Entire Transaction Set
INV
Invoice Instruction
SPH
Special Handling
TRA
Transportation
WHI
Warehouse
Description
Required
String (AN)
Min 1Max 80
A free-form description to clarify the related data elements and their content
070
Carrier Detail
OptionalMax use 5
To specify details of the transportation equipment and carrier routing details
Usage notes
Example: G27M***ROUTING
Example
G27*T*XX*XXX*XXX*XXXXX*XX~
At least one of Standard Carrier Alpha Code (G27-04) or Routing (G27-05) is required
Transportation Method/Type Code
Required
Identifier (ID)
Code specifying the method or type of transportation for the shipment
H
Customer Pickup
M
Motor (Common Carrier)
T
Best Way (Shippers Option)
Equipment Initial
Optional
String (AN)
Min 1Max 4
Prefix or alphabetic part of an equipment unit's identifying number
Equipment Number
Optional
String (AN)
Min 1Max 10
Sequencing or serial part of an equipment unit's identifying number (pure numeric form for equipment number is preferred)
Standard Carrier Alpha Code
Optional
Identifier (ID)
Min 2Max 4
Standard Carrier Alpha Code
Routing
Optional
String (AN)
Min 1Max 35
Free-form description of the routing or requested routing for shipment, or the originating carrier's identity
Shipment/Order Status Code
Optional
Identifier (ID)
Min 2Max 2
Code indicating the status of an order or shipment or the disposition of any difference between the quantity ordered and the quantity shipped for a line item or transaction
080
Terms of Sale
OptionalMax use 20
To specify the terms of sale
- The G23 segment can be used at the header level or detail level, but not both.
When it is used at the detail level, there must be at least one occurrence of the G23 segment for each iteration of the G17 segment.
Usage notes
Example: G2301320060214**220060224102006022511-3923519224891961724***2%10 NET 11
Example
G23*ZZ*5*20231202*02*0*20231202*00*20231202*000*000000*00000*000***X~
At least one of Terms Net Due Date (G23-08) or Terms Net Days (G23-09) is required
Terms Type Code
Required
Identifier (ID)
Code identifying type of payment terms
- If G2301 equals "04" (deferred or installment) then either G2313 or G2314 is required and the data in the segment pertains only to the portion of the invoice described in G2313 or G2314. If G2301 equals "11" (elective) then G2304 is required. If G2301 is not equal to "05"' (discount not applicable) then (G2305 or G2310) and (G2306 or G2307) is required. If G2301 equals "ZZ" (other) then G2315 is required. Multiple use of this segment when G2301 equals "04" (deferred or installment) always implies an "AND" relationship. When G2301 equals "06" (mixed) or "11" (elective) an "OR" relationship is always implied.
01
Basic
02
End of Month (EOM)
03
Fixed Date
07
Extended
08
Basic Discount Offered
ZZ
Other
Terms Basis Date Code
Required
Identifier (ID)
Code identifying the beginning of the terms period
2
Delivery Date
3
Invoice Date
5
Invoice Receipt Date
Terms Start Date
Optional
Date (DT)
CCYYMMDD format
Date from which payment terms are calculated expressed in format CCYYMMDD
Terms Due Date Qualifier
Optional
Identifier (ID)
Code identifying the method to be used for payment in conjunction with due date
02
Product Received by date
Terms Discount Percent
Optional
Decimal number (R)
Min 1Max 6
Terms discount percentage, expressed as a percent, available to the purchaser if an invoice is paid on or before the Terms Discount Due Date
Terms Discount Due Date
Optional
Date (DT)
CCYYMMDD format
Date payment is due if discount is to be earned expressed in format CCYYMMDD
Terms Discount Days Due
Optional
Numeric (N0)
Min 1Max 3
Number of days in the terms discount period by which payment is due if terms discount is earned
Terms Net Due Date
Optional
Date (DT)
CCYYMMDD format
Date when total invoice amount becomes due expressed in format CCYYMMDD
Terms Net Days
Optional
Numeric (N0)
Min 1Max 3
Number of days until total invoice amount is due (discount not applicable)
Terms Discount Amount
Optional
Numeric (N2)
Min 1Max 10
Total amount of terms discount
- G2310 is a memo figure requiring specific payment performance and therefore should not be negative.
Discounted Amount Due
Optional
Numeric (N2)
Min 1Max 10
Amount of invoice due if paid by terms discount due date (total invoice or installment amount less cash discount)
Amount Subject to Terms Discount
Optional
Numeric (N2)
Min 1Max 10
Amount upon which the terms discount amount is calculated
Free Form Message
Optional
String (AN)
Min 1Max 60
Free-form text
090
F.O.B. Information
OptionalMax use 1
To transmit information pertaining to method of freight payment and transfer of title
Usage notes
Example: G25PP02*F.O.B. POINT
Example
G25*PP*04*XX~
Shipment Method of Payment
Required
Identifier (ID)
Code identifying payment terms for transportation charges
CC
Collect
PP
Prepaid (by Seller)
F.O.B. Point Code
Required
Identifier (ID)
Code identifying type of F.O.B. point
02
Destination
03
Plant or Producing Location
04
Point of Origin
F.O.B. Point
Optional
String (AN)
Min 1Max 30
Descriptive name of F.O.B. point
0100 Loop
RequiredMax >1
100
Name
RequiredMax use 1
To identify a party by type of organization, name, and code
- One occurrence of the N1 loop must be used to identify the party to whom the merchandise was shipped.
Usage notes
Example: N1BTC&S WHOLESALE90018424670001
Example
N1*BT*XXXXXX*9*XXXX~
At least one of Name (N1-02) or Identification Code Qualifier (N1-03) is required
If either Identification Code Qualifier (N1-03) or Identification Code (N1-04) is present, then the other is required
Entity Identifier Code
Required
Identifier (ID)
Code identifying an organizational entity, a physical location, property or an individual
BO
Broker or Sales Office
BT
Bill-to-Party
RE
Remit To (MUST SEND)
ST
Ship To
VN
Vendor
Name
Optional
String (AN)
Min 1Max 60
Free-form name
Identification Code Qualifier
Optional
Identifier (ID)
Code designating the system/method of code structure used for Identification Code (67)
9
D-U-N-S+4, D-U-N-S Number with Four Character Suffix
Identification Code
Optional
String (AN)
Min 2Max 80
Code identifying a party or other code
- This segment, used alone, provides the most efficient method of providing organizational identification. To obtain this efficiency the "ID Code" (N104) must provide a key to the table maintained by the transaction processing party.
120
Address Information
OptionalMax use 2
To specify the location of the named party
Usage notes
Example: N347 OLD FERRY ROADPO BOX 821
Example
N3*X*XXXX~
Address Information
Required
String (AN)
Min 1Max 55
Address information
Address Information
Optional
String (AN)
Min 1Max 55
Address information
130
Geographic Location
OptionalMax use 1
To specify the geographic place of the named party
Usage notes
Example: N4BRATTLEBOROVT*053020821
Example
N4*XXXXXX*XX*XXX*XXX~
City Name
Optional
String (AN)
Min 2Max 30
Free-form text for city name
- A combination of either N401 through N404, or N405 and N406 may be adequate to specify a location.
State or Province Code
Optional
Identifier (ID)
Min 2Max 2
Code (Standard State/Province) as defined by appropriate government agency
- N402 is required only if city name (N401) is in the U.S. or Canada.
Postal Code
Optional
Identifier (ID)
Min 3Max 15
Code defining international postal zone code excluding punctuation and blanks (zip code for United States)
Country Code
Optional
Identifier (ID)
Min 2Max 3
Code identifying the country
0200 Loop
OptionalMax >1
140
Allowance or Charge
RequiredMax use 1
To specify allowances, charges, or services
Usage notes
Example: G7250406**644.480000*CA
Example
G72*62*06***00000000*00000*XX*000~
If either Allowance or Charge Quantity (G72-06) or Unit or Basis for Measurement Code (G72-07) is present, then the other is required
Allowance or Charge Code
Required
Identifier (ID)
Code identifying the type of allowance or charge
44
Wholesale Program Fee (invitation only)
47
Price & Marketing Allowance
52
Quantity Discount
53
Freight Allowance
54
Pick-Up Allowance
62
Freshness/Leaker Allowance
90
Performance Allowance
95
Swell Allowance
499
Other Allowance
504
Freight Charge
525
Bottle Deposit
Allowance or Charge Method of Handling Code
Required
Identifier (ID)
Code indicating method of handling for an allowance or charge
02
Off Invoice
06
Charge to be Paid by Customer
Allowance or Charge Rate
Optional
Decimal number (R)
Min 1Max 15
Allowance or Charge Rate per Unit
Allowance or Charge Quantity
Optional
Decimal number (R)
Min 1Max 10
Quantity basis when allowance or charge quantity is different from the purchase order or invoice quantity
Unit or Basis for Measurement Code
Optional
Identifier (ID)
Min 2Max 2
Code specifying the units in which a value is being expressed, or manner in which a measurement has been taken
Allowance or Charge Total Amount
Optional
Numeric (N2)
Min 1Max 15
Total dollar amount for the allowance or charge
150
Allowance or Charge Description
OptionalMax use 10
To describe the allowance or charge in free-form format
Usage notes
Example: G73*FREIGHT CHARGE
Example
G73*XXXXX~
Free-form Description
Required
String (AN)
Min 1Max 45
Free-form descriptive text
Usage notes
This segment is required when G72 segment is sent.
Detail
0300 Loop
OptionalMax >1
010
Item Detail - Invoice
RequiredMax use 1
To specify the basic and most frequently used line item data for the invoice and related transactions
- Either the 0300 loop or the 0400 loop must be used, but both loops cannot be used within a single transaction set.
Usage notes
Example: G1784CA8.37001234567890
Example
G17*000000000*CA*00000000*XXXXXXXXXXXX******000000000*XX~
If either Number of Units Shipped (G17-10) or Unit or Basis for Measurement Code (G17-11) is present, then the other is required
Quantity Invoiced
Required
Decimal number (R)
Min 1Max 10
Number of units invoiced (supplier units)
Unit or Basis for Measurement Code
Required
Identifier (ID)
Code specifying the units in which a value is being expressed, or manner in which a measurement has been taken
- G1702 qualifies G1701.
CA
Case
EA
Each (Number of retail selling units)
LB
Pound
PL
Pallet/Unit Load
Item List Cost
Optional
Decimal number (R)
Min 1Max 9
Gross unit cost within the appropriate price bracket for a line item
U.P.C. Case Code
Optional
String (AN)
Min 12Max 12
Code (Universal Product Code - U.P.C.) including two high order digits identifying the "system" (U.S. Grocery = 00, 06 or 07; U.S. Drug = 03); using the U.S. Grocery system, the next ten digits are: Manufacturer (5) Case Code (5)
Usage notes
UA = Case Code (2-5-5)
Number of Units Shipped
Optional
Decimal number (R)
Min 1Max 10
Numeric value of units shipped in manufacturer's shipping units for a line item or transaction set
Usage notes
If G1701 is a random weight product using the “LB” qualifier in the G1702, than G1710 should state how many cases make up the pounds used.
Unit or Basis for Measurement Code
Optional
Identifier (ID)
Min 2Max 2
Code specifying the units in which a value is being expressed, or manner in which a measurement has been taken
Usage notes
Used when the unit of measure code shipped, differs from the unit of measure code invoiced in G1702 (Refer to G1702 for valid codes).
020
Line Item Detail - Description
OptionalMax use 5
To describe an item in free-form format
Usage notes
Example: G69*PRODUCT DESCRIPTION
Example
G69*X~
Free-form Description
Required
String (AN)
Min 1Max 45
Free-form descriptive text
040
Item Packing Detail
OptionalMax use 1
To specify packing details of the items shipped
Usage notes
Example: G201212*OZ
Example
G20*00000*00000*XX~
If either Size (G20-02) or Unit or Basis for Measurement Code (G20-03) is present, then the other is required
Pack
Optional
Numeric (N0)
Min 1Max 6
The number of inner containers, or number of eaches if there are no inner containers, per outer container
Size
Optional
Decimal number (R)
Min 1Max 8
Size of supplier units in pack
Unit or Basis for Measurement Code
Optional
Identifier (ID)
Min 2Max 2
Code specifying the units in which a value is being expressed, or manner in which a measurement has been taken
0310 Loop
OptionalMax >1
070
Allowance or Charge
RequiredMax use 1
To specify allowances, charges, or services
Usage notes
Example: G724702***.3884CA
Example
G72*95*01***00*00000000*XX*0000000~
If either Allowance or Charge Quantity (G72-06) or Unit or Basis for Measurement Code (G72-07) is present, then the other is required
Allowance or Charge Code
Required
Identifier (ID)
Code identifying the type of allowance or charge
47
Price & Marketing Allowance
52
Quantity Discount
53
Freight Allowance
54
Pick-Up Allowance
62
Freshness/Leaker Allowance
90
Performance Allowance
95
Swell Allowance
499
Other Allowances
504
Freight Charge
525
Bottle Deposit
Allowance or Charge Method of Handling Code
Required
Identifier (ID)
Code indicating method of handling for an allowance or charge
01
Bill Back
02
Off Invoice
06
Charge to be Paid by Customer
Allowance or Charge Rate
Optional
Decimal number (R)
Min 1Max 15
Allowance or Charge Rate per Unit
Allowance or Charge Quantity
Optional
Decimal number (R)
Min 1Max 10
Quantity basis when allowance or charge quantity is different from the purchase order or invoice quantity
Unit or Basis for Measurement Code
Optional
Identifier (ID)
Min 2Max 2
Code specifying the units in which a value is being expressed, or manner in which a measurement has been taken
Allowance or Charge Total Amount
Optional
Numeric (N2)
Min 1Max 15
Total dollar amount for the allowance or charge
080
Allowance or Charge Description
OptionalMax use 10
To describe the allowance or charge in free-form format
Usage notes
Example: G73*Freight Charge
Example
G73*XXXX~
Free-form Description
Required
String (AN)
Min 1Max 45
Free-form descriptive text
Usage notes
This segment is required when G7201 contains code 499 or 999.
Summary
010
Total Invoice Quantity
RequiredMax use 1
To specify summary details of total items shipped in terms of quantity, weight, and volume, and to specify payment method
Usage notes
Example: G311786CA18839LB*
Example
G31*00000000*CA*000*LB~
If either Weight (G31-03) or Unit or Basis for Measurement Code (G31-04) is present, then the other is required
Number of Units Shipped
Required
Decimal number (R)
Min 1Max 10
Numeric value of units shipped in manufacturer's shipping units for a line item or transaction set
Usage notes
Contains the hash total of all G1701 values.
Unit or Basis for Measurement Code
Required
Identifier (ID)
Code specifying the units in which a value is being expressed, or manner in which a measurement has been taken
- G3102 qualifies G3101.
CA
Case
Weight
Optional
Decimal number (R)
Min 1Max 10
Numeric value of weight
Unit or Basis for Measurement Code
Optional
Identifier (ID)
Code specifying the units in which a value is being expressed, or manner in which a measurement has been taken
LB
Pound
020
Total Dollars Summary
RequiredMax use 1
To specify the total invoice amount, including charges less allowances, before terms discount
Usage notes
Example: G33*1961724
Example
G33*000000000000~
Amount
Required
Numeric (N2)
Min 1Max 15
Monetary amount
030
Transaction Set Trailer
RequiredMax use 1
To indicate the end of the transaction set and provide the count of the transmitted segments (including the beginning (ST) and ending (SE) segments)
Example
SE*0000000*0001~
Number of Included Segments
Required
Numeric (N0)
Min 1Max 10
Total number of segments included in a transaction set including ST and SE segments
Transaction Set Control Number
Required
Numeric (N)
Min 4Max 9
Identifying control number that must be unique within the transaction set functional group assigned by the originator for a transaction set
Functional Group Trailer
RequiredMax use 1
To indicate the end of a functional group and to provide control information
Example
GE*0*0000000~
Number of Transaction Sets Included
Required
Numeric (N0)
Min 1Max 6
Total number of transaction sets included in the functional group or interchange (transmission) group terminated by the trailer containing this data element
Group Control Number
Required
Numeric (N0)
Min 1Max 9
Assigned number originated and maintained by the sender
Interchange Control Trailer
RequiredMax use 1
To define the end of an interchange of zero or more functional groups and interchange-related control segments
Example
IEA*00*000000000~
Number of Included Functional Groups
Required
Numeric (N0)
Min 1Max 5
A count of the number of functional groups included in an interchange
Interchange Control Number
Required
Numeric (N0)
Min 9Max 9
A control number assigned by the interchange sender
&S
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article