pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
"no relation entry for relid 1"
8+ messages / 5 participants
[nested] [flat]

* "no relation entry for relid 1"
@ 2011-09-29 20:26  Peter Geoghegan <peter@2ndquadrant.com>
  0 siblings, 2 replies; 8+ messages in thread

From: Peter Geoghegan @ 2011-09-29 20:26 UTC (permalink / raw)
  To: pgsql-bugs

I've built Postgres from master, and found that the following fairly
simple query breaks:

select count(*)
from
(
	select
	schemaname
	from		pg_stat_user_tables
	order by 	1	
) sub
group by schemaname

This produces the internal error message "no relation entry for relid
1". Why is that?

-- 
Peter Geoghegan       http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training and Services



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: "no relation entry for relid 1"
@ 2011-09-29 20:59  Merlin Moncure <mmoncure@gmail.com>
  parent: Peter Geoghegan <peter@2ndquadrant.com>
  1 sibling, 1 reply; 8+ messages in thread

From: Merlin Moncure @ 2011-09-29 20:59 UTC (permalink / raw)
  To: Peter Geoghegan <peter@2ndquadrant.com>; +Cc: pgsql-bugs

On Thu, Sep 29, 2011 at 3:26 PM, Peter Geoghegan <peter@2ndquadrant.com> wrote:
> I've built Postgres from master, and found that the following fairly
> simple query breaks:
>
> select count(*)
> from
> (
>        select
>        schemaname
>        from            pg_stat_user_tables
>        order by        1
> ) sub
> group by schemaname
>
> This produces the internal error message "no relation entry for relid
> 1". Why is that?

hm -- works for me (9.1.0)

merlin



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: "no relation entry for relid 1"
@ 2011-09-29 21:05  Peter Geoghegan <peter@2ndquadrant.com>
  parent: Merlin Moncure <mmoncure@gmail.com>
  0 siblings, 1 reply; 8+ messages in thread

From: Peter Geoghegan @ 2011-09-29 21:05 UTC (permalink / raw)
  To: Merlin Moncure <mmoncure@gmail.com>; +Cc: pgsql-bugs

On 29 September 2011 21:59, Merlin Moncure <mmoncure@gmail.com> wrote:
> hm -- works for me (9.1.0)

It works for me on REL9_1_STABLE too, unsurprisingly, as I would think
it highly unlikely that such a glaring bug would slip into a stable
release.

-- 
Peter Geoghegan       http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training and Services



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: "no relation entry for relid 1"
@ 2011-09-29 21:08  Dickson S. Guedes <listas@guedesoft.net>
  parent: Peter Geoghegan <peter@2ndquadrant.com>
  0 siblings, 1 reply; 8+ messages in thread

From: Dickson S. Guedes @ 2011-09-29 21:08 UTC (permalink / raw)
  To: Peter Geoghegan <peter@2ndquadrant.com>; +Cc: Merlin Moncure <mmoncure@gmail.com>; pgsql-bugs

2011/9/29 Peter Geoghegan <peter@2ndquadrant.com>:
> On 29 September 2011 21:59, Merlin Moncure <mmoncure@gmail.com> wrote:
>> hm -- works for me (9.1.0)
>
> It works for me on REL9_1_STABLE too, unsurprisingly, as I would think
> it highly unlikely that such a glaring bug would slip into a stable
> release.

Have you did a make distclean before build, then init a new $PGDATA?

-- 
Dickson S. Guedes
mail/xmpp: guedes@guedesoft.net - skype: guediz
http://guedesoft.net - http://www.postgresql.org.br



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: "no relation entry for relid 1"
@ 2011-09-29 21:59  Mark Kirkwood <mark.kirkwood@catalyst.net.nz>
  parent: Dickson S. Guedes <listas@guedesoft.net>
  0 siblings, 0 replies; 8+ messages in thread

From: Mark Kirkwood @ 2011-09-29 21:59 UTC (permalink / raw)
  To: Dickson S. Guedes <listas@guedesoft.net>; +Cc: Peter Geoghegan <peter@2ndquadrant.com>; Merlin Moncure <mmoncure@gmail.com>; pgsql-bugs

On 30/09/11 10:08, Dickson S. Guedes wrote:
> 2011/9/29 Peter Geoghegan<peter@2ndquadrant.com>:
>> On 29 September 2011 21:59, Merlin Moncure<mmoncure@gmail.com>  wrote:
>>> hm -- works for me (9.1.0)
>> It works for me on REL9_1_STABLE too, unsurprisingly, as I would think
>> it highly unlikely that such a glaring bug would slip into a stable
>> release.
> Have you did a make distclean before build, then init a new $PGDATA?
>

I can confirm this - checkout from 2 days ago, maintainer-clean + build 
and initdb.



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: "no relation entry for relid 1"
@ 2011-09-29 22:15  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Peter Geoghegan <peter@2ndquadrant.com>
  1 sibling, 1 reply; 8+ messages in thread

From: Tom Lane @ 2011-09-29 22:15 UTC (permalink / raw)
  To: Peter Geoghegan <peter@2ndquadrant.com>; +Cc: pgsql-bugs

Peter Geoghegan <peter@2ndquadrant.com> writes:
> I've built Postgres from master, and found that the following fairly
> simple query breaks:

> select count(*)
> from
> (
> 	select
> 	schemaname
> 	from		pg_stat_user_tables
> 	order by 	1	
> ) sub
> group by schemaname

> This produces the internal error message "no relation entry for relid
> 1". Why is that?

Looks like I broke it here:

http://git.postgresql.org/gitweb/?p=postgresql.git;a=commitdiff;h=1cb108efb0e60d87e4adec38e7636b6e8e...

Fixed, thanks for the report!

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: "no relation entry for relid 1"
@ 2011-09-29 22:50  Peter Geoghegan <peter@2ndquadrant.com>
  parent: Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 8+ messages in thread

From: Peter Geoghegan @ 2011-09-29 22:50 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: pgsql-bugs

On 29 September 2011 23:15, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Peter Geoghegan <peter@2ndquadrant.com> writes:
>> I've built Postgres from master, and found that the following fairly
>> simple query breaks:
>
>> select count(*)
>> from
>> (
>>       select
>>       schemaname
>>       from            pg_stat_user_tables
>>       order by        1
>> ) sub
>> group by schemaname
>
>> This produces the internal error message "no relation entry for relid
>> 1". Why is that?
>
> Looks like I broke it here:
>
> http://git.postgresql.org/gitweb/?p=postgresql.git;a=commitdiff;h=1cb108efb0e60d87e4adec38e7636b6e8e...

Hmm. Although it was obvious to me that this was an internal error, I
have to wonder what a novice would have made of it. Specifically, I
wonder if there should be an INTERNAL_ERROR severity level, to
explicitly advertise that you're not supposed to see this, and to help
log analysis tools (including grep) bring these sorts of things to the
DBA's attention, as they are surely much more severe than most errors
seen in practice.

-- 
Peter Geoghegan       http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training and Services



^ permalink  raw  reply  [nested|flat] 8+ messages in thread

* Re: "no relation entry for relid 1"
@ 2011-09-29 23:21  Tom Lane <tgl@sss.pgh.pa.us>
  parent: Peter Geoghegan <peter@2ndquadrant.com>
  0 siblings, 0 replies; 8+ messages in thread

From: Tom Lane @ 2011-09-29 23:21 UTC (permalink / raw)
  To: Peter Geoghegan <peter@2ndquadrant.com>; +Cc: pgsql-bugs

Peter Geoghegan <peter@2ndquadrant.com> writes:
> On 29 September 2011 23:15, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> Looks like I broke it here:
>> http://git.postgresql.org/gitweb/?p=postgresql.git;a=commitdiff;h=1cb108efb0e60d87e4adec38e7636b6e8e...

> Hmm. Although it was obvious to me that this was an internal error, I
> have to wonder what a novice would have made of it. Specifically, I
> wonder if there should be an INTERNAL_ERROR severity level, to
> explicitly advertise that you're not supposed to see this, and to help
> log analysis tools (including grep) bring these sorts of things to the
> DBA's attention, as they are surely much more severe than most errors
> seen in practice.

Well, the SQLSTATE for this sort of thing is already
ERRCODE_INTERNAL_ERROR.  As to whether it's more severe than other
errors, I'm not convinced.  It didn't crash, nor corrupt your data.

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 8+ messages in thread


end of thread, other threads:[~2011-09-29 23:21 UTC | newest]

Thread overview: 8+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2011-09-29 20:26 "no relation entry for relid 1" Peter Geoghegan <peter@2ndquadrant.com>
2011-09-29 20:59 ` Merlin Moncure <mmoncure@gmail.com>
2011-09-29 21:05   ` Peter Geoghegan <peter@2ndquadrant.com>
2011-09-29 21:08     ` Dickson S. Guedes <listas@guedesoft.net>
2011-09-29 21:59       ` Mark Kirkwood <mark.kirkwood@catalyst.net.nz>
2011-09-29 22:15 ` Tom Lane <tgl@sss.pgh.pa.us>
2011-09-29 22:50   ` Peter Geoghegan <peter@2ndquadrant.com>
2011-09-29 23:21     ` Tom Lane <tgl@sss.pgh.pa.us>

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