Quantcast
Channel: TimescaleDB and PostgreSQL - Timescale Community Forum
Viewing all articles
Browse latest Browse all 291

Insert historical data into continuous aggregate

$
0
0

Hi everybody,

Is there any way to insert historical data into continuous aggregate?

I have two separate problems that such inserting can solve:

  1. I have per-day summation create materialized view data_1day ... as select time_bucket('1 day', ts), sum(value). But now I also have some historical data. I can push them into separate table data_1day_extra and select union out of it and data_1day. But it looks a bit hacky.
  2. I need to add more columns to continuous aggregate. From another topic (Unified view across more continuous aggregates) I understood that the only way is to recreate the whole aggregate. But I need to keep and extend data from the old one, because raw data is long gone.

Thanks!

2 posts - 2 participants

Read full topic


Viewing all articles
Browse latest Browse all 291

Trending Articles