Re: Getting fancy errors when accessing information_schema on 10.5

From: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
To: Axel Rau <Axel(dot)Rau(at)chaos1(dot)de>, pgsql-admin(at)postgresql(dot)org
Subject: Re: Getting fancy errors when accessing information_schema on 10.5
Date: 2018-10-30 07:42:41
Message-ID: 4880e067723cefc1dc2e08a117f96de26ae0f797.camel@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-hackers

Axel Rau wrote:
> here is an example:
>
> SELECT sequence_name AS relname, sequence_schema AS schemaname
> FROM information_schema.sequences
> WHERE sequence_schema NOT LIKE 'pg\_%' AND sequence_schema != ‚information_schema'': SQLSTATE[42809]: Wrong object type: 7 ERROR: "pg_statistic" is not a sequence
>
> This does not happen as SUPERUSER.
> Is this a known bug?

The statement as you wrote it is syntactically incorrect.
Did some program mutilate your quotes in transfer?

Anyway, the error message does not make much sense.
Could you run EXPLAIN on the query and tell us the execution plan?

Perhaps this is some fancy kind of catalog corruption...

Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Axel Rau 2018-10-30 11:32:08 Re: Getting fancy errors when accessing information_schema on 10.5
Previous Message Axel Rau 2018-10-29 22:05:11 Getting fancy errors when accessing information_schema on 10.5

Browse pgsql-hackers by date

  From Date Subject
Next Message David Rowley 2018-10-30 07:58:15 Super PathKeys (Allowing sort order through precision loss functions)
Previous Message Amit Langote 2018-10-30 07:30:22 Re: Should pg 11 use a lot more memory building an spgist index?