Skip to content
Louvre Ops DB

Table

order_line

Products and quantities in an order, with the price charged.

Replaces in 2020: Invoices

Rows 5,001–5,025 of 5,412

order_line, page 201 of 217
order_id→ purchase_order.order_idproduct_id→ product.product_idquantityINTEGERunit_price_centsINTEGER
5001151500
5002121500
5003121500
5004211700
5005121500
5006211700
500731800
500841400
5009121500
5010111500
5011221700
5012241700
5013221700
501431800
501541400
501641400
5017121500
5018111500
501941400
5020121500
5021211700
5022121500
5023111500
5024121500
5025121500
Table definition
CREATE TABLE order_line (
  order_id         INTEGER NOT NULL REFERENCES purchase_order (order_id),
  product_id       INTEGER NOT NULL REFERENCES product (product_id),
  quantity         INTEGER NOT NULL CHECK (quantity > 0),
  unit_price_cents INTEGER NOT NULL CHECK (unit_price_cents >= 0),
  PRIMARY KEY (order_id, product_id)
) STRICT;