CREATE TABLE BasicProduct (
  productId integer,
  supplement integer,
  passive integer
);

CREATE TABLE Deliverable (
  deliverableId integer,
  compensatableAmount double precision,
  productId integer,
  sizeOf char(20),
  passive integer
);

CREATE TABLE DeliverableName (
  name character(50),
  deliverableId integer,
  languageName character(20)
);

CREATE TABLE Fingerprints (
  fingerprint bytea,
  userId integer
);

CREATE TABLE Language (
        languageName char(20)
);

CREATE TABLE AllBrought (
  amount double precision,
  when2 date,
  userId integer,
  productId integer
);

CREATE TABLE AllConsumed(
        amount double precision,
        when2 date,
        userId integer,
        productId integer
);

CREATE TABLE Portion (
        sizeOf double precision,
        productId integer
);

CREATE TABLE ProductName (
        name char(50),
        productId integer,
        languageName char(20)
);
CREATE TABLE Supplement (
        userId integer,
        productId integer,
        supplementId integer
);

CREATE TABLE Users (
        userId integer,
        name char(50),
        passive integer,
        languageName char(20)
);

INSERT INTO language VALUES ('finnish');
INSERT INTO language VALUES ('swedish');
INSERT INTO language VALUES ('english');
