Skip to content
Louvre Ops DB

Table

order_line

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

Replaces in 2020: Invoices

Rows 2,226–2,250 of 5,412

order_line, page 90 of 217
order_id→ purchase_order.order_idproduct_id→ product.product_idquantityINTEGERunit_price_centsINTEGER
2226221700
2227121500
2228221700
222931800
2230251700
223131800
2232211700
2233111500
2234251700
2235121500
2236241700
223731800
223831800
2239221700
224031800
2241221700
2242221700
2243251700
224431800
224531800
224631800
2247211700
2248211700
2249121500
2250131500
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;