Search Postgresql Archives

Re: Correct Concept On Table Partition

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In response to Yan Cheng Cheok :
> Currently, I plan to use table partition to solve the following problem.
> I have a table which is going to grow to a very huge row, as time goes on.
> As I know, as table grow larger, the read operation will be slower.
> 
> Hence, I decide to use table partition, in order to improve read speed.
> ...
> 
> First 1st millions rows will be write to measurement_1, 2nd millions into measurement_2, ....
> 
> 
> Is this the correct expectation, on table partition?

Depends on your selects. You needs an attribute to decide which
child-table contains your data.

For instance, create tables for every month. Now you can 'select ...
where date >= '2010-01-01'::date and date < '2010-02-01'::date to select
all data for this particular month.

Your child-tables should contains contraints to enforce this
partitioning-schema.

There are a lot of examples in the internet how to do that, for instance:
http://www.if-not-true-then-false.com/2009/11/howto-create-postgresql-table-partitioning-part-1/


Regards, Andreas
-- 
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG: 0x31720C99, 1006 CCB4 A326 1D42 6431  2EB0 389D 1DC2 3172 0C99

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux