List:General Discussion« Previous MessageNext Message »
From:Ben Clewett Date:May 16 2008 1:44pm
Subject:Replication advise
View as plain text  
Dear MySql,

Hope somebody might give some advise about replication!

On 5.1.24, I have something simple like:

CREATE TABLE big_f_er (
   id BIGINT UNSINGED NOT NULL AUTO_INCREMENT,
   t TIMESTAMP NULL NOT NULL,
   PRIMARY KEY (id, t),
   KEY (t)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
PARTITION BY RANGE ( YEAR(t) )
(
   PARTITION p0 VALUES LESS THAN (2006),
   PARTITION p1 VALUES LESS THAN (2007),
   PARTITION p2 VALUES LESS THAN (2008),
   (etc...)
);

Into which I plan to dump several terabytes of an exiting v.large table.

Looking at EXPLAIN PARTITIONS I have noticed that these SQL statement 
correctly select the partition:

   SELECT WHERE t =
   SELECT WHERE t IN

But these select all partition tables:

   SELECT WHERE t >
   SELECT WHERE t BETWEEN

So, my question is, without having to re-write several billion lines of 
code, is there a way I can make all these examples correctly select the 
partition table?

Any help very welcome!

Regards,

Ben
Thread
Replication adviseBen Clewett16 May
  • Re: Replication adviseRob Wultsch16 May