- (optional) Create database
CREATE DATABASE winds;
- Connect to database
\connect winds;
- Create table
CREATE TABLE wind_pwr_spd(
time TIMESTAMP NOT NULL PRIMARY KEY,
speed NUMERIC,
power NUMERIC
);
- Insert data
Full insert command set to import dataset.csv can be found in insert.sql
Example:
INSERT INTO wind_pwr_spd(time, power, speed) VALUES (NOW(), 3055.86957961, 25);