Answers for "laravel add foreign key to not existing table"

PHP
0

Laravel create foreign key column in migration

$table->foreignId('post_id')
                ->constrained()
                ->onUpdate('cascade')
                ->onDelete('cascade');
Posted by: Guest on July-18-2021

Code answers related to "laravel add foreign key to not existing table"

Browse Popular Code Answers by Language