Questions tagged [timescaledb]

An open-source time-series SQL database optimized for fast ingest and complex queries. Packaged as a PostgreSQL extension. QUESTIONS MUST BE ABOUT PROGRAMMING in order to be on-topic on Stack Overflow. Specifically, database administration is not on-topic for Stack Overflow.

TimescaleDB

TimescaleDB is an open-source database designed to make SQL scalable for time-series data. It is engineered up from PostgreSQL, providing automatic partitioning across time and space (partitioning key). It speaks full SQL and is correspondingly easy to use like a traditional relational database, yet scales in ways previously reserved for NoSQL databases.

Compared to the trade-offs demanded by these two alternatives (relational vs. NoSQL), TimescaleDB offers the best of both worlds for time-series data:

Features

Easy to Use

  • Full SQL interface for all SQL natively supported by PostgreSQL (including secondary indexes, non-time based aggregates, sub-queries, JOINs, window functions).
  • Connects to any client or tool that speaks PostgreSQL, no changes needed.
  • Time-oriented features, API functions, and optimizations.
  • Robust support for Data retention policies.

Scalable

  • Transparent time/space partitioning for both scaling up (single node) and scaling out (forthcoming).
  • High data write rates (including batched commits, in-memory indexes, transactional support, support for data backfill).
  • Right-sized chunks (two-dimensional data partitions) on single nodes to ensure fast ingest even at large data sizes.
  • Parallelized operations across chunks and servers.

Reliable

  • Engineered up from PostgreSQL, packaged as an extension.
  • Proven foundations benefiting from 20+ years of PostgreSQL research (including streaming replication, backups).
  • Flexible management options (compatible with existing PostgreSQL ecosystem and tooling).

Resources

691 questions
3
votes
1 answer

Group by bursts of occurences in TimescaleDB/PostgreSQL

this is my first question in stackoverflow, any advice on how to ask a well structured question will be welcomed. So, I have a TimescaleDB database, which is time-series databases built over Postgres. It has most of its functionalities, so if any of…
3
votes
0 answers

Can not call procedure by JPA - could not determine data type of parameter

When trying to call procedure with timestamp parameters by the code: SimpleJdbcCall simpleJdbcCall = new SimpleJdbcCall(dataSource) .withSchemaName("time_series") …
grzesiu988
  • 184
  • 3
  • 14
3
votes
0 answers

Is there a way to monitor timescaleDB statefulset pod using Prometheus itself?

I am using Prometheus + promscale + timescaleDB + grafana to monitor my kubernetes cluster. I tried using postgress-exporter to listen to timescaleDB metrics but the queries did not work. And there is no timescale-exporter. How does one show…
ssbb191
  • 1,486
  • 3
  • 12
  • 23
3
votes
1 answer

Continuous aggregates in postgres/timescaledb requires time_bucket-function?

I have a SELECT-query which gives me the aggregated sum(minutes_per_hour_used) of some stuff. Grouped by id, weekday and observed hour. SELECT id, extract(dow from observed_date) AS weekday, ( --observed_date is type date …
AndreasInfo
  • 1,062
  • 11
  • 26
3
votes
1 answer

Storing Docker PostgreSQL data to an Azure Storage Account

tell me how can I store PostgreSQL database data in an Azure Storage account. The PostgreSQL deploy to Azure Container Instance. When I restart the Azure Container instance all data disappears. Dockerfile FROM timescale/timescaledb:latest-pg12 ENV…
3
votes
2 answers

Unable to use TimescaleDB in Rails test environment

I'm stuck using TimescaleDB in Rails - everything works fine in development, but in my test suite I cannot insert any data. What I tried A) Use SQL schema dump This causes the original error message I saw. It does create parts of the schema for…
AxelTheGerman
  • 986
  • 13
  • 26
3
votes
0 answers

TimescaleDB continuous aggregates and Postgis

I'm trying to come up with a database design, and I can't wrap my head around a proper setup. Given my requirements, I thought about TimescaleDB and Postgis, but I quickly hit some issues with continuous aggregates. Inputs: batches of 10 million…
Martín Coll
  • 3,368
  • 3
  • 37
  • 52
3
votes
2 answers

TimescaleDB: Understanding the return values after creating hypertable and the creation of chunks after populating the hypertable

I have an existing table in my database named price (has 264 rows) and I converted it into a hypertable price_hypertable doing: CREATE TABLE price_hypertable (LIKE price INCLUDING DEFAULTS INCLUDING CONSTRAINTS EXCLUDING INDEXES); SELECT…
some_programmer
  • 3,268
  • 4
  • 24
  • 59
3
votes
1 answer

Timescale DB interpolation on JSON fields

I am currently working on a project that stores IOT information as JSON in Postgresql, and I decided to use timescale extension because I require some functionality like interpolation for when a component goes down or so for an hour or so. I am…
3
votes
1 answer

How to improve the performance of timescaledb getting last timestamp

SELECT timeseries_id, "timestamp" FROM enhydris_timeseriesrecord WHERE timeseries_id=6661 ORDER BY "timestamp" DESC LIMIT 1; (The table contains about 66m records, and the ones with timeseries_id=6661 are about 0.5m.) This query takes about 1-2…
Antonis Christofides
  • 6,990
  • 2
  • 39
  • 57
3
votes
1 answer

Can jooq recognize optional parameters for routines and create overloads accordingly?

we use jooq in a Kotlin/Java environment to access a timescaledb. Now, oftentimes when we regenerate the jooq objects we get errors if there was a change in the signature of a routine on the db even though it just added optional parameters. Can I…
fhueser
  • 599
  • 3
  • 16
3
votes
1 answer

Update all time index in a TimescaleDB/PostgreSQL hypertable?

I am using an open-source time-series database named TimescaleDB ( based on PostgreSQL ). Assuming this table : CREATE TABLE order ( time TIMESTAMPTZ NOT NULL, product text, price DOUBLE…
A. STEFANI
  • 6,707
  • 1
  • 23
  • 48
3
votes
1 answer

Gap filling by group (not equal start date)

I have a dataset where each sku (grouped by stores) has different start date: date sku store Units balance 0 2019-10-01 103993.0 001 0.0 10.0 1 2019-10-02 103993.0 001 1.0 9.0 2 2019-10-04 103993.0 …
Cesar
  • 575
  • 3
  • 16
3
votes
1 answer

TimescaleDB compress chunks during after first insertion of older data

I have a TimescaleDB hypertable that breaks in chunks by every 1-month interval based in my timestamp column. Does TimescaleDB use the same timestamp column to define when a chunk has to be compressed? If so, how is the best method to handle the…
Sassa
  • 1,673
  • 2
  • 16
  • 30
3
votes
2 answers

How to determine if a table has Timescale enabled and on which columns?

I have a Timescale database that someone else created. How do I determine if create_hypertable was called on a table ? For now I use this, but there must be a better way: SELECT * FROM hypertable_relation_size('public.data'); And if…
rjdkolb
  • 10,377
  • 11
  • 69
  • 89