php - Insert batch in Laravel 5 -


i using laravel 5. have tried insert following data in laravel using insert. not working anymore.

i have $permission array contains following array detials.

array ( [0] => array     (         [permission_id] => 1         [role_id] => 1     )  [1] => array     (         [permission_id] => 2         [role_id] => 1     )  [2] => array     (         [permission_id] => 3         [role_id] => 1     )  [3] => array     (         [permission_id] => 4         [role_id] => 1     ) )  db::table('permission_role')->insert($permission) 

array (     array     (         [permission_id] => 1,         [role_id] => 1,     ),      array     (         [permission_id] => 2,         [role_id] => 1,     ),     array     (         [permission_id] => 3,         [role_id] => 1,     ),     array     (         [permission_id] => 4,         [role_id] => 1,     ) ) 

Comments

Popular posts from this blog

android - Gradle sync Error:Configuration with name 'default' not found -

java - Andrioid studio start fail: Fatal error initializing 'null' -

html - jQuery UI Sortable - Remove placeholder after item is dropped -