How to store user's tastes
From: ^Bart <gabriele1NOSPAM_at_hotmail.com>
Date: Sun, 21 Apr 2019 19:07:03 +0200
Message-ID: <q9i7vl$1bd4$1_at_gioia.aioe.org>
[Quoted] Hello everybody!
Date: Sun, 21 Apr 2019 19:07:03 +0200
Message-ID: <q9i7vl$1bd4$1_at_gioia.aioe.org>
[Quoted] Hello everybody!
[Quoted] I need to create a DB where I should store user's tastes or user's foodstyle (vegan, vegetarian, etc.)
CREATE TABLE foodstyles
(
id_foodstyle BIGINT(7) NOT NULL AUTO_INCREMENT,
name VARCHAR(50) NOT NULL UNIQUE,
FK_id_ingredient SMALLINT(7) NOT NULL,
PRIMARY KEY (id_foodstyle),
INDEX (FK_id_ingredient),
FOREIGN KEY (FK_id_ingredient) REFERENCES ingredients (id_ingredient)
)
ENGINE=INNODB;
In this case I should repeat the name vegan a lot of times:
name | FK_id_ingredient vegan | 4 vegan | 2 vegan | 8 vegan | 9 vegan | 3
[Quoted] How could I find the best way to store informations in a group named vegan with a lot of things?
^Bart Received on Sun Apr 21 2019 - 19:07:03 CEST