Skip to content

4b. Accessing data with SQL

Melanie Jans-Singh edited this page May 17, 2021 · 2 revisions

In this page, I paste a few SQL commands which can be useful to visualise the data.

Identify the first and last timestamp udpated

SELECT MIN(timestamp)
FROM energy_data
UNION
SELECT MAX(timestamp)
FROM energy_data

Select all unique values in table column

SELECT DISTINCT (sensor_id) FROM utc_energy_data