title: Can't make migration to Laravel SQLSTATE[42703]
body: <p>I keep getting an error when trying to do a database migration</p>
  <pre><code>SQLSTATE[42703]: Undefined column: 7 ERROR:  column &quot;user_id&quot; referenced in foreign key constraint does not exist (SQL: alter table &quot;ads&quot; add constraint &quot;ads_user_id_foreign&quot; foreign key (&quot;user_id&quot;) references &quot;users&quot; (&quot;id&quot;))
  </code></pre>
  <p>This is my migration file</p>
  <pre><code>public function up()
  {
      Schema::create('ads', function (Blueprint $table) {
          $table-&gt;id();
          $table-&gt;foreign('user_id')-&gt;references('id')-&gt;on('users');
          $table-&gt;foreign('category_id')-&gt;references('id')-&gt;on('categories');
          $table-&gt;foreign('city_id')-&gt;references('id')-&gt;on('cities');
          $table-&gt;string('title');
          $table-&gt;text('description');
          $table-&gt;text('photos');
          $table-&gt;string('status');
          $table-&gt;timestamps();
      });
  }
  </code></pre>