pg_class.relpages/allvisible probably shouldn't be a int4 - Mailing list pgsql-hackers

From Andres Freund
Subject pg_class.relpages/allvisible probably shouldn't be a int4
Date
Msg-id 20140509172903.GJ30231@awork2.anarazel.de
Whole thread Raw
Responses Re: pg_class.relpages/allvisible probably shouldn't be a int4
List pgsql-hackers
Hi,

postgres=# SELECT relpages FROM pg_class WHERE relname = 'large'; relpages
--------------1804468224
(1 row)

postgres=# \dt+ large                  List of relationsSchema | Name  | Type  | Owner  | Size  | Description
--------+-------+-------+--------+-------+-------------public | large | table | andres | 19 TB |
(1 row)

That's nothing for 9.4 anymore, but shouldn't we make pg_class.relpages
a int8 (sounds slightly better than float to me) or somesuch?

I think most calculations actually work out because they're performed
after casting to BlockNumber, but ...

Greetings,

Andres Freund

PS: _mdfd_getseg is considered harmful(). Not fun once you have couple
of hundred gigabytes.

--Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



pgsql-hackers by date:

Previous
From: Alexander Korotkov
Date:
Subject: Re: [COMMITTERS] pgsql: Clean up jsonb code.
Next
From: Josh Berkus
Date:
Subject: Re: How can we make beta testing better?