-
Notifications
You must be signed in to change notification settings - Fork 0
/
vinylshop.sql
201 lines (166 loc) · 5.25 KB
/
vinylshop.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
-- phpMyAdmin SQL Dump
-- version 5.2.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Apr 24, 2023 at 01:22 PM
-- Server version: 10.4.27-MariaDB
-- PHP Version: 8.2.0
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;
--
-- Database: `vinylshop`
--
-- --------------------------------------------------------
--
-- Table structure for table `album`
--
CREATE TABLE `album` (
`ID` int(11) NOT NULL,
`titel` varchar(22) NOT NULL DEFAULT '',
`artiest` varchar(15) NOT NULL DEFAULT '',
`genre` varchar(15) NOT NULL DEFAULT '',
`prijs` decimal(5,2) NOT NULL DEFAULT 0.00,
`voorraad` int(11) NOT NULL DEFAULT 0
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci;
--
-- Dumping data for table `album`
--
INSERT INTO `album` (`ID`, `titel`, `artiest`, `genre`, `prijs`, `voorraad`) VALUES
(1, 'Cafe Atlantico', 'Cesarie Evora', 'World', 3.00, 100),
(2, 'Rumba Azul', 'Caetano Veloso', 'Latin', 4.90, 50),
(3, 'Survivor', 'Destiny\'s Child', 'R&B', 3.00, 789),
(4, 'Oh Girl', 'The Chi-lites', 'Pop', 3.00, 2),
(5, 'Der Her ist mei getreu', 'Ton Koopman', 'Klasiek', 5.50, 30),
(6, 'Closing Time', 'Tom Waits', 'Rock', 3.00, 0),
(7, 'Irresistible', 'Celia Cruz', 'Latin', 3.50, 23),
(8, 'Marvin Gaye II', 'Marvin Gaye', 'R&B', 4.00, 154),
(9, 'Mi Sangre', 'Juanes', 'Latin', 3.90, 123),
(10, 'Greatest Hits 2', 'Queen', 'Rock', 3.00, 0),
(11, '3121', 'Prince', 'Rock', 3.45, 0),
(12, 'Antologia I', 'Paco de Lucia', 'World', 3.00, 320);
-- --------------------------------------------------------
--
-- Table structure for table `item`
--
CREATE TABLE `item` (
`ID` int(11) NOT NULL,
`weborder_ID` int(11) NOT NULL,
`album_ID` int(11) NOT NULL,
`verkoopprijs` decimal(5,2) NOT NULL,
`aantal` tinyint(2) NOT NULL DEFAULT 0
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci;
--
-- Dumping data for table `item`
--
INSERT INTO `item` (`ID`, `weborder_ID`, `album_ID`, `verkoopprijs`, `aantal`) VALUES
(1, 1, 1, 3.00, 1),
(2, 1, 5, 5.50, 2),
(3, 2, 8, 4.00, 1),
(4, 2, 10, 3.00, 2),
(5, 3, 1, 3.00, 1),
(6, 4, 5, 5.50, 1),
(7, 4, 8, 4.00, 1),
(8, 4, 6, 3.00, 1),
(9, 5, 4, 3.00, 2),
(10, 5, 6, 3.00, 1),
(11, 5, 1, 3.00, 1),
(12, 5, 9, 3.90, 1),
(13, 5, 10, 3.00, 3);
-- --------------------------------------------------------
--
-- Table structure for table `klant`
--
CREATE TABLE `klant` (
`ID` int(11) NOT NULL,
`voornaam` varchar(20) NOT NULL DEFAULT '',
`naam` varchar(20) NOT NULL DEFAULT '',
`adres` varchar(20) NOT NULL DEFAULT '',
`postcode` varchar(6) NOT NULL DEFAULT '',
`woonplaats` varchar(20) NOT NULL DEFAULT '',
`email` varchar(20) NOT NULL DEFAULT ''
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci;
--
-- Dumping data for table `klant`
--
INSERT INTO `klant` (`ID`, `voornaam`, `naam`, `adres`, `postcode`, `woonplaats`, `email`) VALUES
(1, 'Dylan', 'Huisden', 'Middenweg 11', '1088VV', 'Amsterdam', '[email protected]'),
(2, 'Nitin', 'Bosman', 'Leidseweg 22', '9900BB', 'Amsterdam', '[email protected]'),
(3, 'Joseph', 'Demirel', 'Leidseplein 33', '9988BB', 'Utrecht', '[email protected]'),
(4, 'Franco', 'Tasiyan', 'Kruislaan 444', '3300VV', 'Utrecht', '[email protected]'),
(5, 'Akash', 'Kabli', 'Galileiplantsoen 333', '2299NN', 'Amstelveen', '[email protected]'),
(6, 'Tamara', 'Kabli', 'Mozartstraat 22', '3388XX', 'Amsterdam', '[email protected]'),
(7, 'Arnold', 'Shaw', 'Kruislaan 1', '9876FF', 'Rotterdam', '[email protected]');
-- --------------------------------------------------------
--
-- Table structure for table `weborder`
--
CREATE TABLE `weborder` (
`ID` int(11) NOT NULL,
`klant_ID` int(5) NOT NULL,
`datum` date NOT NULL DEFAULT '0000-00-00'
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci;
--
-- Dumping data for table `weborder`
--
INSERT INTO `weborder` (`ID`, `klant_ID`, `datum`) VALUES
(1, 1, '2015-01-01'),
(2, 1, '2015-01-01'),
(3, 2, '2015-02-15'),
(4, 3, '2015-02-20'),
(5, 3, '2015-03-13');
--
-- Indexes for dumped tables
--
--
-- Indexes for table `album`
--
ALTER TABLE `album`
ADD PRIMARY KEY (`ID`);
--
-- Indexes for table `item`
--
ALTER TABLE `item`
ADD PRIMARY KEY (`ID`);
--
-- Indexes for table `klant`
--
ALTER TABLE `klant`
ADD PRIMARY KEY (`ID`);
--
-- Indexes for table `weborder`
--
ALTER TABLE `weborder`
ADD PRIMARY KEY (`ID`);
--
-- AUTO_INCREMENT for dumped tables
--
--
-- AUTO_INCREMENT for table `album`
--
ALTER TABLE `album`
MODIFY `ID` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=13;
--
-- AUTO_INCREMENT for table `item`
--
ALTER TABLE `item`
MODIFY `ID` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=17;
--
-- AUTO_INCREMENT for table `klant`
--
ALTER TABLE `klant`
MODIFY `ID` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;
--
-- AUTO_INCREMENT for table `weborder`
--
ALTER TABLE `weborder`
MODIFY `ID` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;
COMMIT;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;