This question already has an answer here:
I'm testing a laravel site using codeception and I've followed the following tute:
I'm getting the following error:
[Illuminate\Database\QueryException] SQLSTATE[HY000]: General error: 1 Cannot add a NOT NULL column with default value NULL (SQL: alter table "markers" add column "user_id" integer not null)
Thanks in advance.
</div>
Your real problem is called ALTER TABLE. If you want to add NOT NULL column, you need to set DEFAULT for existing records! Otherwise, what can the database do?