SET @add_user_withdraw_usdt_trc20_address := (
  SELECT IF(
    COUNT(*) = 0,
    'ALTER TABLE users ADD COLUMN withdraw_usdt_trc20_address VARCHAR(128) NOT NULL DEFAULT '''' COMMENT ''提现 USDT-TRC20 地址'' AFTER contact_info',
    'SELECT 1'
  )
  FROM information_schema.COLUMNS
  WHERE TABLE_SCHEMA = DATABASE()
    AND TABLE_NAME = 'users'
    AND COLUMN_NAME = 'withdraw_usdt_trc20_address'
);

PREPARE stmt FROM @add_user_withdraw_usdt_trc20_address;
EXECUTE stmt;
DEALLOCATE PREPARE stmt;
