Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit fc9b645

Browse files
committed
Update disk space computation because oids are now optional.
1 parent 14720f7 commit fc9b645

File tree

2 files changed

+16
-16
lines changed

2 files changed

+16
-16
lines changed

doc/FAQ

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Frequently Asked Questions (FAQ) for PostgreSQL
33

4-
Last updated: Thu Aug 11 09:21:58 EDT 2005
4+
Last updated: Thu Sep 1 12:17:52 EDT 2005
55

66
Current maintainer: Bruce Momjian (pgman@candle.pha.pa.us)
77

@@ -489,23 +489,23 @@
489489
twenty bytes in length. The flat file would be 2.8 MB. The size of the
490490
PostgreSQL database file containing this data can be estimated as 6.4
491491
MB:
492-
32 bytes: each row header (approximate)
492+
28 bytes: each row header (approximate)
493493
24 bytes: one int field and one text field
494494
+ 4 bytes: pointer on page to tuple
495495
----------------------------------------
496-
60 bytes per row
496+
56 bytes per row
497497

498498
The data page size in PostgreSQL is 8192 bytes (8 KB), so:
499499

500500
8192 bytes per page
501-
------------------- = 136 rows per database page (rounded down)
502-
60 bytes per row
501+
------------------- = 146 rows per database page (rounded down)
502+
56 bytes per row
503503

504504
100000 data rows
505-
-------------------- = 735 database pages (rounded up)
506-
128 rows per page
505+
-------------------- = 685 database pages (rounded up)
506+
146 rows per page
507507

508-
735 database pages * 8192 bytes per page = 6,021,120 bytes (6 MB)
508+
685 database pages * 8192 bytes per page = 5,611,520 bytes (5.6 MB)
509509

510510
Indexes do not require as much overhead, but do contain the data that
511511
is being indexed, so they can be large also.

doc/src/FAQ/FAQ.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
alink="#0000ff">
1111
<H1>Frequently Asked Questions (FAQ) for PostgreSQL</H1>
1212

13-
<P>Last updated: Thu Aug 11 09:21:58 EDT 2005</P>
13+
<P>Last updated: Thu Sep 1 12:17:52 EDT 2005</P>
1414

1515
<P>Current maintainer: Bruce Momjian (<A href=
1616
"mailto:pgman@candle.pha.pa.us">pgman@candle.pha.pa.us</A>)
@@ -635,23 +635,23 @@ <H3><A name="4.5">4.5</A>) How much database disk space is required
635635
The size of the PostgreSQL database file containing this data can
636636
be estimated as 6.4 MB:</P>
637637
<PRE>
638-
32 bytes: each row header (approximate)
638+
28 bytes: each row header (approximate)
639639
24 bytes: one int field and one text field
640640
+ 4 bytes: pointer on page to tuple
641641
----------------------------------------
642-
60 bytes per row
642+
56 bytes per row
643643

644644
The data page size in PostgreSQL is 8192 bytes (8 KB), so:
645645

646646
8192 bytes per page
647-
------------------- = 136 rows per database page (rounded down)
648-
60 bytes per row
647+
------------------- = 146 rows per database page (rounded down)
648+
56 bytes per row
649649

650650
100000 data rows
651-
-------------------- = 735 database pages (rounded up)
652-
128 rows per page
651+
-------------------- = 685 database pages (rounded up)
652+
146 rows per page
653653

654-
735 database pages * 8192 bytes per page = 6,021,120 bytes (6 MB)
654+
685 database pages * 8192 bytes per page = 5,611,520 bytes (5.6 MB)
655655
</PRE>
656656

657657
<P>Indexes do not require as much overhead, but do contain the data

0 commit comments

Comments
 (0)