laravelによって作成され、私は移行ファイルを得た溶液を塗布した後How is a pivot table created by laravelで同じ問題を発見し、私は私の変更を行ってきましたがどのようにピボットテーブルは、私が<a href="http://four.laravel.com/docs/eloquent#many-to-many" rel="nofollow noreferrer">http://four.laravel.com/docs/eloquent#many-to-many</a>ですべてを続く5
public function up()
{
Schema::table('Card_User', function (Blueprint $table) {
$table->increments('id');
$table->integer('Card_id');
$table->integer('User_id');
$table->integer('additional_var');
});
}
しかしとき
:私は、私はいつも私が試したいくつかの他のウェブページへのfolowwing後[Illuminate\Database\QueryException]
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'db.Card_User' d
oesn't exist (SQL: alter table `Card_User` add `id` int unsigned not null auto
_increment primary key, add `Card_id` int not null, add `User_id` int not null
, add `additional_var` int not null)
[PDOException]
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'waawia.Card_User' d
oesn't exist
を取得
php artisan migrate:refresh
にしてみてください
php artisan migrate:install
...手動ですべてのデータベーステーブルを削除し、
が
php artisan serve
を再開し、今ではいくつかの他の事を閉じています移行をリフレッシュしかし、まだ同じ問題がある
ありがとうございました:私はたくさん働いていましたが、今までそれを見つけられませんでした。あなたの答えを最高のものとして選びます。ちょっと^ _ ^ありがとうございます –