EDIFACT LIN segment: line item.

The LIN segment begins a line item group and carries the line number and product identifier. Element 1 is the line number (sequential, starting at 1). Element 3 is a composite containing the product ID and its type code. Each LIN is followed by PIA, IMD, QTY, PRI, MOA, TAX, and other segments that describe the line.

Tag
LIN
Full name
Line item
Part of the message
Line items
Data elements
5

A LIN segment, explained

Hover any part of the segment to see what it is. Open What your system receives to see the JSON or XML CleanEDI delivers.

  1. LIN+1++9312345678901:EN'
    LINLine item

    Line 1: item 9312345678901 (GTIN barcode).

    LIN
    Line item
    EN
    GTIN barcode (item number type)

LIN structure

Elements are separated by + and their parts by :. Positions match the explainer, so 2.3 is the third part of the second element.

PositionElementParts
1Line numberSingle value
2Action2.1 Code
3Item3.1 Number, 3.2 Number type
4Sub-lineSingle value
5Configuration levelSingle value

Action (2.1)

CodeMeaning
1Added
3Changed
5Accepted without amendment
7Not accepted

Item: Number type (3.2)

CodeMeaning
ENGTIN barcode
SRVGTIN barcode
SASupplier's article number
INBuyer's item number
BPBuyer's part number
MFManufacturer's article number
UPUPC

Common EANCOM and UN/EDIFACT values. Your trading partner's implementation guide is the final word on which codes they send.

LIN segment FAQ

Have a real message with LIN in it? The explainer breaks down every segment and runs in your browser.

Explain my message

What is the LIN segment in EDIFACT?

LIN is the Line Item segment. The LIN segment begins a line item group and carries the line number and product identifier. Element 1 is the line number (sequential, starting at 1). Element 3 is a composite containing the product ID and its type code. Each LIN is followed by PIA, IMD, QTY, PRI, MOA, TAX, and other segments that describe the line.

What are the common LIN action codes?

1 means added; 3 means changed; 5 means accepted without amendment; 7 means not accepted.

Where does LIN appear in an EDIFACT message?

LIN belongs to the line items part of a message, alongside PIA, IMD, ALI, QTY, PRI, MOA.

How do I read a LIN segment in my own message?

Paste the message into the free CleanEDI explainer. It breaks every LIN segment into its elements, translates the codes and shows the JSON and XML your system would receive. Nothing you paste leaves your browser.

Related segments in line items