목록MySQL (2)
미래기록
Illuminate\Database\QueryException : SQLSTATE[HY000]: General error: 3780 PDOException::("SQLSTATE[HY000]: General error: 3780 Referencing column... 에러코드 Schema::create('client_information', function (Blueprint $table) { $table->bigIncrements('id'); $table->integer('user_id')->unsigned()->index(); $table->foreign('user_id')->references('id')->on('users..
SQLSTATE[42000]: Syntax error or access violation: 1072 Key column 'user_id' doesn't exist in table Laravel에서 migration파일에 생성할 테이블코드를 작성하고 migrate할 때 위와 같은 에러가 뜰 때 해결법. 외래키 설정부분에서 문제가 있었던 것 에러코드 Schema::create('shop_information', function (Blueprint $table) { $table->bigIncrements('id'); $table->foreign('user_id')->references('id')->on('users')..