# Order difference management

This feature compares purchase invoice amounts with the purchase orders the received goods come from. For each invoice line linked to a receipt, the expected amount based on the order and the difference from the invoiced amount are calculated. When the invoice is released, if the difference exceeds the configured tolerances, the invoice is flagged as "To Be Checked" and, if configured, put on hold.

Also available:

- a **differences worksheet** to correct line costs and automatically post the difference to a dedicated account;
- a **Purchase Order Differences** report to print the order/invoice comparison and mark invoices as checked.



The **Purchases & Payables Setup** page contains the **Order Difference** group:

| Field | Description |
|---|---|
| Order Difference Calculation | **Sum**: positive and negative line differences offset each other. **Sum (absolute)**: every difference is taken as an absolute (always positive) value, so differences do not offset. |
| Order Tolerance Amount (plus) | Maximum allowed difference, as an amount, when the invoice exceeds the order. |
| Order Tolerance % (plus) | Maximum allowed difference, as a percentage of the invoice amount, when the invoice exceeds the order. |
| Order Tolerance Amount (minus) | Maximum allowed difference, as an amount, when the invoice is lower than the order. Editable only with the **Sum** calculation. |
| Order Tolerance % (minus) | Maximum allowed difference, as a percentage, when the invoice is lower than the order. Editable only with the **Sum** calculation. |
| Order Difference On Hold | Code entered in the invoice's **On Hold** field when the tolerances are exceeded. |
| Order Difference Account | G/L account used by the differences worksheet to create adjustment lines. |

If all tolerances are zero, no check is performed on release.


The **G/L Account Card** has the **Purchase Diff. Account** field. Invoice lines of type G/L Account using an account with this option enabled are considered entirely as order difference (for example the adjustment lines created by the differences worksheet).


| Page | Field | Description |
|---|---|---|
| Purchase Invoice (header, after **Check Total**) | Order Difference Amount | Sum of the invoice line differences. Not editable. |
| Purchase Invoice lines (hidden by default) | Order Difference | Difference between the line amount and the amount expected from the order. |
| | Receipt Amount | Line amount calculated with the purchase order prices for the invoiced quantity. |
| Purchase Invoices and Posted Purchase Invoices (lists, hidden by default) | Order Difference Status | Blank, **To Be Checked** or **Checked**. |
| | Order Difference Amount | Total of the document differences. |
| Posted Purchase Invoice Lines (hidden by default) | Receipt Amount, Order Difference | Values carried over from the posted invoice. |

Hidden fields can be added to the view by personalizing the page.



Whenever the amounts of a purchase invoice line are recalculated:

- if the line comes from a receipt, the **Receipt Amount** is calculated as the net cost of the original order line multiplied by the invoiced quantity, and the **Order Difference** is the invoiced amount minus the receipt amount;
- if the line is of type G/L Account on an account with **Purchase Diff. Account** enabled, the whole amount is considered a difference;
- with the **Sum (absolute)** calculation, the difference is always stored as a positive value.


When you release a purchase invoice not yet marked as **Checked**:

1. the difference status is cleared and, if the invoice was on hold with the configured code, the hold is removed;
2. the **Order Difference Amount** is compared with the tolerances (plus if positive, minus if negative; both as an amount and as a percentage of the invoice amount);
3. if a tolerance is exceeded, the invoice moves to **To Be Checked** status and you are asked "Invoice exceed order tolerance. Continue?". Answering No cancels the release; answering Yes continues and, if configured, puts the invoice on hold with the **Order Difference On Hold** code.

Invoices already marked as **Checked** are released without further checks.


In the **Purchase Invoices** and **Posted Purchase Invoices** lists, when the **Order Difference Status** field is **To Be Checked**, click the field's assist button: after confirmation the status becomes **Checked**. Unposted invoices must be released.

Alternatively, use the **Set as checked** option of the **Purchase Order Differences** report (see below).


From the **Purchase Invoices** list, choose the **Differences Worksheet** action to open the **Purchase Order Difference Worksheet** for the selected invoice. The worksheet shows the invoice lines coming from receipts (or return shipments) with a non-zero quantity.

| Field | Description |
|---|---|
| Type, No., Description | Invoice line data. |
| Item Reference No. | First bar code of the item. |
| Vendor Item No. | Vendor item number from the item card. |
| Quantity, Unit of Measure Code | Invoiced quantity. |
| Direct Unit Cost, Line Discount % | Line cost and discount. Additional discounts are also available, hidden by default, if enabled. |
| Amount | Net line amount. |
| Receipt Amount | Amount expected from the order. |
| Order Difference | Difference between invoiced and expected amount. |
| Unit Net Cost | Current unit net cost of the line (amount / quantity). |
| New Unit Net Cost | Corrected unit net cost. Editable. |
| Comment | Free text saved as a line comment. Editable. |
| Difference Amount | Total (at the bottom of the page) of the difference generated by the new costs entered. |


| Action | Description |
|---|---|
| Apply Changes | Applies the corrections to the invoice (see procedure). |
| Open document | Opens the source invoice (or credit memo). |
| Open shipment/receipt | Opens the posted receipt or posted return shipment of the line. |
| Open order | Opens the purchase order or return order the line comes from. |


1. Open the worksheet with the **Differences Worksheet** action.
2. For the lines to correct, enter the **New Unit Net Cost** and, if useful, a **Comment**. The **Difference Amount** updates with each change.
3. Choose **Apply Changes** and confirm.

As a result:

- for each line whose new cost differs from the current one, the line discount is cleared and the **Direct Unit Cost** is set to the new net cost;
- the comments entered are added as invoice line comments;
- for each VAT product posting group, a G/L Account line on the **Order Difference Account** is added to the invoice, with quantity 1 and cost equal to the calculated difference, so that the invoice total stays the same;
- the worksheet closes.

The **Order Difference Account** must be filled in on the **Purchases & Payables Setup**.


Run the report with the **Order Differences** action from the **Purchase Invoices** and **Posted Purchase Invoices** lists, for the selected invoices. For each invoice it shows the header (vendor, document date, vendor invoice no., order difference status) and the lines with quantity, invoice amount, order amount and difference.

On the request page, **Options** tab, the **Set as checked** option sets all printed invoices to **Checked** status, after confirmation.