Small query yields "error: no relation entry for relid 11" - Mailing list pgsql-bugs

From Tom Ellis
Subject Small query yields "error: no relation entry for relid 11"
Date
Msg-id 20201205173056.GF30712@cloudinit-builder
Whole thread Raw
Responses Re: Small query yields "error: no relation entry for relid 11"
List pgsql-bugs
This small query results in "error: no relation entry for relid 11" in
Postgres 12 and 13 (beta) on db-fiddle.com.  It runs fine in Posgres
11.

Tom


SELECT 0
      FROM
      (SELECT 0) as "T1"
      LEFT OUTER JOIN
      (SELECT * FROM (SELECT *
        FROM
        (SELECT
         0) as "T1"
        LEFT OUTER JOIN
        (SELECT
         TRUE as "r") as "T2"
        ON
        TRUE) as "T1",
       LATERAL
       (SELECT
        TRUE as "b"
        UNION ALL
        SELECT
        CASE WHEN "r" THEN TRUE ELSE TRUE END as "b") as "T2"
        ) as "T2"
      ON
      "b"



pgsql-bugs by date:

Previous
From: Andy S
Date:
Subject: Re: BUG #16763: CREATE TABLE IF NOT EXISTS fails with "relation exists"
Next
From: Tom Lane
Date:
Subject: Re: Small query yields "error: no relation entry for relid 11"