3
ExtremeDating - a Hackathon 2013 project.
4
Copyright (C) 2013 Gustav Hartvigsson <gustav.hartvigsson@gmail.com>
5
Copyright (C) 2013 Daniel Johansson <maila@danieljohansson.nu>
8
This program is free software: you can redistribute it and/or modify
9
it under the terms of the GNU Affero General Public License as
10
published by the Free Software Foundation, either version 3 of the
11
License, or (at your option) any later version.
13
This program is distributed in the hope that it will be useful,
14
but WITHOUT ANY WARRANTY; without even the implied warranty of
15
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
GNU Affero General Public License for more details.
18
You should have received a copy of the GNU Affero General Public License
19
along with this program. If not, see <http://www.gnu.org/licenses/>.
22
$db = new PDO("sqlite:./database.db");
24
$db->setAttribute(PDO::ATTR_ERRMODE,
25
PDO::ERRMODE_EXCEPTION);
29
Users(_loginName_, shadow, firstName, surname, city, eMail);
30
Resturants(_id_, name, city, phoneNumber, theme);
31
# Theme is if it is, say, a pizzeria or a french resturant or something.
32
Interests(_interest_);
34
UserInterests(-loginName-, -interest-, -foodType-);
38
CREATE TABLE IF NOT EXISTS Users(
39
loginName varchar(64) NOT NULL,
40
shadow varchar(64) NOT NULL,
41
firstName varchar(64) NOT NULL,
42
surname varchar(64) NOT NULL,
43
city varchar(64) NOT NULL,
44
eMail varchar(64) NOT NULL,