From: PG Bug reporting form <noreply@postgresql.org>
To: pgsql-bugs@lists.postgresql.org
Cc: fernando.asulay@es.abb.com
Subject: BUG #18410: SQL Error [XX000]: ERROR: variable not found in subplan target list
Date: Wed, 27 Mar 2024 12:42:33 +0000
Message-ID: <18410-b6ad04652311ce33@postgresql.org> (raw)
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));
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-bugs@postgresql.org
Cc: noreply@postgresql.org, pgsql-bugs@lists.postgresql.org, fernando.asulay@es.abb.com
Subject: Re: BUG #18410: SQL Error [XX000]: ERROR: variable not found in subplan target list
In-Reply-To: <18410-b6ad04652311ce33@postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox