download

Description

Product download information of order.

Definition

Column Type Constraint Description
shop TEXT PRIMARY KEY Shop ID. (shop.username)
order_id INTEGER Order ID. (order.id)
index INTEGER Index of ordered products. (order_product.index)
code INTEGER NOT NULL Indentification code.
remaining INTEGER NOT NULL Remaining number of download.

Related tables

Query

CREATE TABLE download (
  shop       TEXT,
  order_id   INTEGER,
  index      INTEGER,
  code       TEXT,
  remaining  INTEGER,

  PRIMARY KEY(shop, order_id, index)
);