我只有一个新的迁移文件,它是2017_02_05_121119_create_posts_table.php,但当我运行"php artisan migrate“时,它显示"Symfony\Component\Debug\Exception\FatalErrorException无法重新声明类CreateUsersTable”。
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreatePostsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('posts', function (Blueprint $table) {
$table->increments('id');
$table->string('title');
$table->string('description');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('posts');
}
}
https://stackoverflow.com/questions/42052048
复制相似问题