Relative Content

Tag Archive for postgresqltimescaledb

TimescaleDB carry forward then aggregate in buckets

I have a table that contains IoT updates from many devices. I’d like to calculate an average for each hour based on the device readings. I would like those readings to be carried forward before aggregating. I don’t have readings for each hour, there are gaps.

TimescaleDB query occasionally VERY slow

We’re using TimescaleDB in an IoT environment, so doing quite a lot of inserts with no issues. In this case however, we’re seeing this particular SELECT query sometimes be very slow (10-15 seconds), even in the QA environment with very low load. The normal execution time is around 400ms (across VPN using pgAdmin).

Hypertable foreign key

I have a problem with Timescale. I want to add foreign key referencing a regular table in my hypertable so that it then will be populated among my continuous aggregate views. I would like to achieve only one way relation.
for example having hypertable: