Purchase Orders

Some vendors support the use of EDI orders to handle orders for their inventory. Alma supports sending orders to vendors via EDI. In Alma, EDI is defined as one of the possible channels of communication with the vendors (in addition to emails, SMS, and submission). If a vendor is defined as an EDI vendor that supports orders (that is, the POs check box is selected in the EDI Information tab), Alma attempts to send the order via EDI. The invoice structure in EDI is as follows:

see EDIfact standard for orders.

Order Information Segments

  1. UNH (header):

UNH+{message number}+ORDERS:D:96A:UN:EAN008’

  • message number– the sender’s unique message reference number. By convention, incorporates a sequence number of the message within the interchange.
  • ORDERS – purchase order
  • D – message type version number
  • 96A = message type release number – EDIFACT Directory D.96A
  • UN = controlling agency
  • EAN008 = association-assigned code – EAN version number
  1. BGM (Beginning of Message):

BGM+{order type}+{order number}+{message function}’

  • order type – 220 (order), 224 (rush order), 228 (sample order), 22C (continuation order)
  • order number – order number assigned by document sender: mandatory in EANCOM
  • message function – 9 (original), 7 (duplicate)
  1. DTM (Date Time Message):

DTM+137:{message date}:102′

  • message date – in CCYYMMDD format
  1. NAD (Name and Address) – In this application, there will be two mandatory occurrences per message to show buyer and supplier, and up to two additional occurrences to show a delivery address and an invoicing address, if different from the buyer’s address. Note that only NAD and RFF segments 9 and 11 are used in this application
  • BY/SU – qualifier:
  • BY – Buyer
  • DP = delivery party, if different from buyer
  • IV = invoiced party, if different from buyer
  • SU = supplier
  • 5013546027856 – PARTY IDENTIFICATION – If possible, use coded – preferably an EAN code. The following is an example of a name and address:
NAD+BY+++Stadt- und Universitätsbibliothek Buyer identified by structured text :FfM:Erwerbungsabteil+Bockenheimer Landstrasse 134:PO Box 1006+FRANKFURT++60325+DE’
  1. RFF REFERENCE – One or two optional occurrences per segment group: RFF+API:DAWS’
  • API – reference qualifier:
  • API = additional party identification. Use with a NAD segment coded BY in DE 3035 for a coded identification, which is additional to the linked NAD segment. Typically, this may be a supplier’s own code for a library account or customer department (EAN code).
  • IA = internal vendor number. Use with a NAD segment coded SU in DE 3035 when a library has multiple vendor references which apply to different types of business with the same supplier.
  • VA = VAT registration number
  1. CUX (currency) Required in international trading, otherwise optional. One occurrence per message to show the default currency in which prices in the order are provided:

CUX+2:{currency code}:9′

  • currency code – ISO 4217 three-alpha code:
  1. LIN (order line item) – One mandatory occurrence per order line. In this application, the IN segment is used only to carry the line sequence number, or the line sequence number and an EAN-13 article number. Sub-lines are not used in library book orders.

LIN+{order line number}++{item number}:EN’

  • order line number – line sequence number, starting at one and incremented by one for each successive line. For example, LIN+5’ = line item number 5.
  • item number – item number EAN-13 article number (optional)
  • EN – EAN. mandatory if an EAN-13 article number is used
  1. PIA (additional product id) – One or more occurrences are used in this application to send an ISBN and/or a supplier’s own product code – either as the main product identifier (where no EAN number was given in LIN segment 39), or as an additional identifier. If no product code is available, the PIA segment is omitted, and the product must be fully identified by a description in IMD segment 41. An additional occurrence may be used to identify an acceptable substitute for the product ordered.

PIA+{function code}+{item number}:{item number type}’

  • function code – Product ID function code:
    1:additional identification – Use when the PIA segment carries an identifier in addition to the main product identifier (for example, a supplier’s own code sent in addition to the ISBN or EAN number).
    1S: additional identification – an identification number for a multi-volume or multi-part set to which the product belongs
    2: identification of an acceptable substitute
    5: main product identification – Use when the PIA segment carries the main product code (normally the ISBN).
    5S: ‘start from’ product number (EDItEUR code) – Use only in a continuation order message coded 22C in BGM DE 1001, to give the ISBN or other identifier of the volume in a series from which the order begins (see also IMD segment 41).
    5V = ‘set or series including’ product number (EDItEUR code) – Use when the order refers to a set or series for which the only ISBN or other product number available at the time of ordering is that of one or more volumes or parts
  • item number type:
    EN: EAN-13 article number
    IB: ISBN (International Standard Book Number)
    IM: ISMN (International Standard Music Number)
    IS: ISSN (International Standard Serial Number) – Use only in a continuation order message coded 22C in BGM DE 1001, to identify the series to which the order applies.
    MF: manufacturer’s article number
    SA: supplier’s article number
  1. IMD (item description): up to 99 repeats of IMD segment may be used to give bibliographic details of the item to which the order line refers. This is mandatory if the item is not identified by a code or codes in LIN segment 39 and/or PIA segment 40. Where the text of a bibliographic data element exceeds 70 characters, additional repeats of the segment, carrying the same code in DE 7081, may be used as “continuation” segments.

IMD+{Item description type code}+{Item characteristic code}+:::{Item characteristic}’

  • Item description type code:
    C: coded, EDItEUR format codes in DE 7009, DE 7081 = BFM. (This code will be withdrawn in a future general revision of EDItEUR standards; do not use in new implementations.)
    F: free-form, EDItEUR alpha codes in DE 7081. (These codes will be withdrawn in a future general revision of EDItEUR standards; do not use in new implementations.)
    L: text, EDItEUR numeric codes in DE 7081 (EDItEUR code)
  • Item characteristic code:
    A table describing all the possible values and their meaning can be found in EDItEUR Library EDI Implementation Guidelines, Version 1.2 on the EDItEUR Web site. The following are some examples:
    001 – short author/title description, for example, PRESTON/FRANCO: A BIOGRAPHY, 2ND ED
    009 – name of book author, editor or other contributor (unstructured), for example, Paul Preston
    010 – name of first author, editor, and so forth(surname or entry element), for example, Preston
    050 – title, for example, Franco: a Biography
    100 – edition statement, for example, 2nd ed
    109 – publisher, unstructured, for example, HarperCollins
    170 – date of publication, for example, 1997
    220 – binding, for example, paperback
  1. QTY (quantity): One mandatory occurrence per order line to provide the quantity ordered


  • quantity – number of ordered copies
  1. FTX (free text): One or more optional occurrences (up to a maximum of 99 per order line), using EDItEUR Code Lists 4441:1B, 3B, 4B or 10B to indicate, in coded form, conditions that apply to the order line, and which are exceptions to the parties’ general trading agreement. The segment may also be used to attach a free text message to the order line, but this is to be avoided if possible.
  1. PRI (price details): One mandatory occurrence per repeat of SG28 to specify a unit price. In library book supply, where the basis of an order is normally the publisher’s fixed or suggested retail price – which may be quoted with or without tax where applicable, and with discounts and/or servicing charges applied thereafter – the most commonly expected coding of the PRI segment is: DE 5125 = AAB or AAE DE 5375 = CA DE 5387 = SRP or RTP

PRI+{price qualifier}:{price}:{price type}’

  • price qualifier – price qualifier:
    AAA – calculation price net (the unit price which will actually be charged by the supplier excluding tax, but including any allowances or charges)
    AAB – calculation price gross (the supplier’s unit price excluding all taxes, allowances, or charges)
    AAE – information price (including tax, but excluding any allowances or charges)
    AAF – information price (including all taxes, allowances, or charges)
  • price – mandatory unless DE 5387 = FOC or NQT. Price, in the format NN.DD, where NN is an integer of up to 11 digits, and DD represents up to 4 decimal places. Insignificant zeros are not sent (for example, 5.2 is sent, not 5.20 or 05.20).
  • price type – coded optional; the following code values may be used:
    CA – publisher’s catalogue price
    DI – distributor’s (that is, a bookseller’s or an agent’s) price
    NE – not to exceed. Use in order to set an upper limit when the price is not known.
    PV – provisional price. Use if the publisher’s firm price is not known on the order date.
    QT – quoted price
  1. CUX (currencies): May be used if, and only if, the price in PRI segment 49 is not in the order currency. Exchange rates are not provided in this application.

CUX+2:{currency code}:10′

  • currency code – ISO 4217 three-alpha code
  1. RFF (reference): Up to 10 occurrences per order line may be used to provide references that apply to the current line only. The buyer’s unique order line number (LI or LCO) is mandatory in this application and should appear in the first occurrence of the RFF segment.

RFF+{reference qualifier}:{reference number}’

  • reference qualifier:
    AE – authorization for expense number. Use for a library’s “blanket” purchase authorization number, covering multiple orders.
    BFN – buyer’s fund number (EDItEUR code)
    IA – internal vendor number. Use for the buyer’s internal reference for the supplier, when a library has multiple vendor references that apply to different types of business with the same supplier
    LCO – library’s continuation order number. Use only in a message coded 22C in BGM segment 2, DE 1001 (EDItEUR code)
    LI – buyer’s unique order line number (mandatory)
    QLI – supplier’s unique quotation line number (EDItEUR code)
    SLI – supplier’s unique order line reference number (EDItEUR code)

15. GIR (General Item Related data) –

  1. the GIR segment is used to enable “copy-related” or “part-order-related” data to be sent in an ORDERS message. (“Part-order” means a quantity of copies within a single order line which have common characteristics and/or servicing requirements.)

For PROQUEST EDI Type of vendor and Physical PO Line, the LOC Segment was removed and if the Order has any item/Holdings data the GIR will be displayed even if the item does not have Item policy and Call number.

  1. LOC (place/location identification): Indicates a special delivery location for the whole quantity, or for partial quantities of the order line.
  2. QTY (quantity): May be used to indicate the delivery quantity for the location specified in LOC segment 58.
  3. TDT (details of transport): One optional occurrence per order line is used to request a specific transport method.
  4. UNS (section control): One mandatory occurrence per message:


  1. CNT (control total): At least one occurrence per message is recommended, to send a control total of the number of line items.

CNT+{control qualifier}:{control total}’

  • control qualifier:
    1 – total value of QTY segments in the message (sum of DE 6060s from QTY segment 43)
    2 – number of line items (LIN segments) in the message
  • control total – sent as an integer

Order EDI sample: