laravel migration not null code example
Example 1: check if value is not null in db laravel
Model::whereNotNull('sent_at')
Example 2: laravel migration on delete set null
$table->...->onDelete('set null');
Example 3: migrations required field laravel
$table->string('foo')->nullable(false)->change();