CREATE TABLE products (id INTEGER PRIMARY KEY NOT NULL, name TEXT, amount INTEGER NOT NULL DEFAULT 0);
CREATE TABLE purchases (user INTEGER NOT NULL DEFAULT 0, product INTEGER NOT NULL DEFAULT 0, timestamp INTEGER NOT NULL DEFAULT 0);
CREATE TABLE restock (user INTEGER NOT NULL DEFAULT 0, product INTEGER NOT NULL DEFAULT 0, amount INTEGER NOT NULL DEFAULT 0, timestamp INTEGER NOT NULL DEFAULT 0);
CREATE TABLE prices (product INTEGER NOT NULL DEFAULT 0, valid_from INTEGER NOT NULL DEFAULT 0, memberprice INTEGER NOT NULL DEFAULT 0, guestprice INTEGER NOT NULL DEFAULT 0);
CREATE TABLE users (id INTEGER PRIMARY KEY NOT NULL, email TEXT, firstname TEXT NOT NULL, lastname TEXT NOT NULL, gender TEXT, street TEXT, plz INTEGER, city TEXT);
BEGIN TRANSACTION;
INSERT INTO products VALUES(40084015,'Duplo',42);
INSERT INTO products VALUES(40084107,'Ü-Ei',64);
INSERT INTO products VALUES(40111315,'Twix',30);
INSERT INTO products VALUES(40114606,'KitKat',45);
INSERT INTO products VALUES(40358802,'Knoppers',41);
INSERT INTO products VALUES(76222498,'Milka Tender milch',15);
INSERT INTO products VALUES(76222504,'Milka Tender nuss',13);
INSERT INTO products VALUES(4001686128244,'Haribo Staffeten',28);
INSERT INTO products VALUES(4001686150689,'Haribo Konfekt',19);
INSERT INTO products VALUES(4001686216125,'Haribo Salino',23);
INSERT INTO products VALUES(4001686301265,'Haribo Goldbären',24);
INSERT INTO products VALUES(4001686309506,'Haribo Happy Cherries',10);
INSERT INTO products VALUES(4001686310229,'Haribo Weinland',22);
INSERT INTO products VALUES(4001686312025,'Haribo Schnuller',18);
INSERT INTO products VALUES(4001686313046,'Haribo Saure Bohnen',17);
INSERT INTO products VALUES(4001686315101,'Haribo Happy Cola',20);
INSERT INTO products VALUES(4001686367346,'Haribo Tropifrutti',21);
INSERT INTO products VALUES(4001686386613,'Haribo Saftgoldbären',3);
INSERT INTO products VALUES(4001686390085,'Haribo Phantasia',11);
INSERT INTO products VALUES(4001686720028,'Haribo Colorado Mini',0);
INSERT INTO products VALUES(4001686721445,'Haribo Color-Rado',18);
INSERT INTO products VALUES(4003586000477,'Chips Frisch Ungarisch',18);
INSERT INTO products VALUES(4003586000491,'Chips Frisch Oriento',22);
INSERT INTO products VALUES(4006220013185,'Orangen Saft',0);
INSERT INTO products VALUES(4007495314014,'Gouda Käse-Sticks',28);
INSERT INTO products VALUES(4029764001807,'Club Mate',112);
INSERT INTO products VALUES(4047046003325,'Senseo Klassisch',29);
INSERT INTO products VALUES(4047046003356,'Senseo Mild',16);
INSERT INTO products VALUES(4047046003417,'Senseo Entkoffeiniert',16);
INSERT INTO products VALUES(4047046005008,'Senseo Cappuccino Choco',8);
INSERT INTO products VALUES(4104450004086,'Vilsa medium',19);
INSERT INTO products VALUES(4104450004383,'Limette',64);
INSERT INTO products VALUES(4104450005878,'Vilsa Classic',1);
INSERT INTO products VALUES(5000159407236,'Mars',16);
INSERT INTO products VALUES(5000159407397,'Snickers',6);
INSERT INTO products VALUES(5000159407410,'Snickers (2x)',48);
INSERT INTO products VALUES(5000159418539,'Balisto Jogurt Beeren Mix',36);
INSERT INTO products VALUES(5000159418546,'Balisto Muesli-Mix',40);
INSERT INTO products VALUES(5000159418577,'Balisto Korn-Mix',40);
INSERT INTO products VALUES(5449000017888,'Coka Cola',56);
INSERT INTO products VALUES(5449000017895,'Coka Cola Light',65);
INSERT INTO products VALUES(5449000017918,'Fanta',67);
INSERT INTO products VALUES(5449000017932,'Sprite',52);
INSERT INTO products VALUES(5449000134264,'Coka Cola Zero',55);
INSERT INTO products VALUES(7613032625474,'Lion',50);
INSERT INTO products VALUES(7613032850340,'KitKat Chunky',22);
INSERT INTO products VALUES(8410036002015,'Freixenet Cava Semi Seco 0.75L',3);
INSERT INTO products VALUES(8690504018568,'Üker Sesamsticks',5);
COMMIT;
