| 12345678910111213141516171819202122232425262728293031323334 |
- -- 两个开关默认关闭,保留现有账号的短链处理方式。
- SET @column_exists := (
- SELECT COUNT(*)
- FROM information_schema.columns
- WHERE table_schema = DATABASE()
- AND table_name = 'tk_pool'
- AND column_name = 'enable_general_link_parse_pool'
- );
- SET @sql := IF(
- @column_exists = 0,
- 'ALTER TABLE tk_pool ADD COLUMN enable_general_link_parse_pool TINYINT(1) NOT NULL DEFAULT 0 COMMENT ''加入万能解析账号池''',
- 'SELECT 1'
- );
- PREPARE stmt FROM @sql;
- EXECUTE stmt;
- DEALLOCATE PREPARE stmt;
- SET @column_exists := (
- SELECT COUNT(*)
- FROM information_schema.columns
- WHERE table_schema = DATABASE()
- AND table_name = 'tk_pool'
- AND column_name = 'use_general_link_parse_pool'
- );
- SET @sql := IF(
- @column_exists = 0,
- 'ALTER TABLE tk_pool ADD COLUMN use_general_link_parse_pool TINYINT(1) NOT NULL DEFAULT 0 COMMENT ''使用万能解析账号池处理短链''',
- 'SELECT 1'
- );
- PREPARE stmt FROM @sql;
- EXECUTE stmt;
- DEALLOCATE PREPARE stmt;
|