The following bug has been logged on the website:
Bug reference: 14578
Logged by: François Beausoleil
Email address: francois@teksol.info
PostgreSQL version: 9.6.2
Operating system: Mac OS 10.11.6
Description:
In my schema, I happen to have two tables in different schemas with the same
name. PG supports that no problem, but when I listed the tables using \dt
and the search path set to both schemas, I expected to see the two tables.
Sadly, that wasn't the case.
https://gist.github.com/francois/2db220bd197492d02e0b60224a7576ac
-- repro.sql
create schema mybank;
create table public.a();
create table mybank.a();
set search_path to public;
\dt
set search_path to mybank;
\dt
set search_path to mybank, public;
\dt
set search_path to public, mybank;
\dt
-- run
$ psql --no-psqlrc --quiet repro -f b.sql
List of relations
Schema | Name | Type | Owner
--------+------+-------+----------
public | a | table | francois
(1 row)
List of relations
Schema | Name | Type | Owner
--------+------+-------+----------
mybank | a | table | francois
(1 row)
List of relations
Schema | Name | Type | Owner
--------+------+-------+----------
mybank | a | table | francois
(1 row)
List of relations
Schema | Name | Type | Owner
--------+------+-------+----------
public | a | table | francois
(1 row)
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs