📅  最后修改于: 2022-03-11 14:54:08.155000             🧑  作者: Mango
//The UNique need be a constraint name
// This name has this format:
// [TABLE_NAME]_[COLUMN_NAME]_unique
// For 'users' table and 'user_code' column, whe get the name:
// users_user_code_unique
$table->dropUnique('users_user_code_unique');
//The inverst is
$table->unique('user_code');