INVOICE

This table stores the invoice XML generated for the order release. An order release is represented by a row in the ORDRELEASE table.


Column Descriptions:

Name Type Description
INVOICE_ID BIGINT NOT NULL Generated unique key for this row. Also used as the invoice number.
ORDERS_ID BIGINT NOT NULL The ID of the order. The ORDERS_ID and the order release number together are the primary key to the row in the ORDRELEASE table.
ORDRELEASENUM INTEGER NOT NULL Order release number. The ORDERS_ID and the order release number together are the primary key to the row in the ORDRELEASE table.
INVOICEXML CLOB (1000000) The invoice XML for this order release.
STATUS CHAR (4) Reserved for IBM internal use.
TIMECREATED TIMESTAMP Time the invoice XML is generated.
OPTCOUNTER SMALLINT NOT NULL DEFAULT 0 The optimistic concurrency control counter for the table. Every time there is an update to the table, the counter is incremented.


Indexes:

Name Column Names Type
<SYSTEM-GENERATED> INVOICE_ID Primary Key
I0000596 ORDERS_ID Non-Unique Index


Constrained By Parent Tables:

Constraint Columns Parent Table Parent Columns Type
F_397 ORDERS_ID ORDERS ORDERS_ID Cascade