-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcreate_table.sql
More file actions
28 lines (22 loc) · 788 Bytes
/
Copy pathcreate_table.sql
File metadata and controls
28 lines (22 loc) · 788 Bytes
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
-- Creates the tables needed to store environmental data
CREATE TABLE envdata(
id BIGINT UNSIGNED AUTO_INCREMENT PRIMARY KEY,
time TIMESTAMP NOT NULL,
sensor TINYTEXT NOT NULL,
humidity DOUBLE NOT NULL,
pressure DOUBLE NOT NULL,
temperature_from_humidity DOUBLE NOT NULL,
temperature_from_pressure DOUBLE NOT NULL,
orientation_pitch DOUBLE NOT NULL,
orientation_roll DOUBLE NOT NULL,
orientation_yaw DOUBLE NOT NULL,
compass_x DOUBLE NOT NULL,
compass_y DOUBLE NOT NULL,
compass_z DOUBLE NOT NULL,
gyroscope_pitch DOUBLE NOT NULL,
gyroscope_roll DOUBLE NOT NULL,
gyroscope_yaw DOUBLE NOT NULL,
accelerometer_pitch DOUBLE NOT NULL,
accelerometer_roll DOUBLE NOT NULL,
accelerometer_yaw DOUBLE NOT NULL
);