いくつかのテーブルを日付範囲で分割する必要があります。これらのテーブルを分割するには、プライマリを削除するか、完全なデータを再ロードする必要がありますか?
一部のテーブルには、5,000 万行をはるかに超える行が含まれています。
alter table temp_table_test1
partition by range (unix_timestamp(created_at))
(
partition p01 values less than (unix_timestamp('2015-02-01')),
partition p02 values less than (unix_timestamp('2015-02-01')),
partition p03 values less than (unix_timestamp('2015-02-01')),
partition p04 values less than (unix_timestamp('2015-02-01')),
partition p02 values less than (maxvalue)
);
これは私が使用しているスクリプトです。