The following bug has been logged on the website:
Bug reference: 18410
Logged by: Fernando Asulay
Email address: fernando.asulay@es.abb.com
PostgreSQL version: 16.2
Operating system: TimescaleDB linux Docker image
Description:
The issue was found to happend on timescaledb extension hypertables using
postgres 14 and above. We tested different version of timescaledb and
doesn't seem to take any effect. Only changing pg version from 13 to 14.
Tested using images from
https://hub.docker.com/r/timescale/timescaledb/tags
To reproduce the error:
The following compose was used:
version: "3.5"
services:
works:
image: timescale/timescaledb:2.14.2-pg13
container_name: works
restart: always
environment:
POSTGRES_USER: admin
POSTGRES_PASSWORD: password
ports:
- "5432:5432"
doesntwork:
image: timescale/timescaledb:2.14.2-pg14
container_name: doesntwork
environment:
POSTGRES_USER: admin
POSTGRES_PASSWORD: password
ports:
- "5433:5432"
doesntworkeither:
image: timescale/timescaledb:2.14.2-pg16
container_name: doesntworkeither
environment:
POSTGRES_USER: admin
POSTGRES_PASSWORD: password
ports:
- "5434:5432"
connect to "doesntwork" or "doesntworkeither" containers and run the
following SQL:
-- Create test table
CREATE TABLE public.test1(
id text NOT null,
created timestamptz NOT NULL
);
-- Make the table an timescaledb hypertable
SELECT create_hypertable('public.test1', 'created', chunk_time_interval =>
interval'4 days');
-- Insert some data
INSERT INTO public.test1 VALUES (1, '2024-01-01');
-- Verify data is correclty inserted
SELECT * FROM public.test1;
-- Run the query to trigger the error
DELETE FROM
"public".test1
WHERE
(EXISTS (SELECT 1));