I would do this to make my email field unique
in the table.
$table->unique('email');
我试过了
public function up()
{
Schema::table('contacts', function(Blueprint $table)
{
$table->dropUnique('email');
});
}
然后,当我运行php artisan migrate时,我得到了这个
It tell me that it's not there, but I'm 100% sure that it's there.
How do write a migration to undo that ?