# mysql-sequence **Repository Path**: bigflyFish/mysql-sequence ## Basic Information - **Project Name**: mysql-sequence - **Description**: mysql下的单库分表的全局sequence - **Primary Language**: Java - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2017-01-20 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README #mysql-sequence 分布式下单库分表的全局sequence ,见 doc/目录下 建sequence表 从您的库中挑出几个库(1-4个即可)来建立sequence表,例如本例在TDDL5_00_GROUP和TDDL5_01_GROUP上建立sequence表,建表语句为: CREATE TABLE `sequence` ( `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT, `name` varchar(64) NOT NULL, `value` bigint(20) NOT NULL, `gmt_create` timestamp not null default '0000-00-00 00:00:00' , `gmt_modified` timestamp not null default current_timestamp on update current_timestamp , PRIMARY KEY (`id`), UNIQUE KEY `unique_name` (`name`) ) ENGINE=InnoDB DEFAULT CHARSET=utf 8;