Try
mysql -u username -p database_name < file.sql
via CLI.
Be careful with large sql files, it's might be better to split your sql dump, because there is an execution time limit.
And is there a way to import .sql-files inside PHP/Laravel?
I dump the SQL for the individual tables and then in seeders named appropriately I do:
public function run() { DB::unprepared(File::get('path/to/SQL/file')); }
psychonetic said:
Be careful with large sql files, it's might be better to split your sql dump, because there is an execution time limit.
via PMA yes, but not by CLI.
Sharping said:
And is there a way to import .sql-files inside PHP/Laravel?
if you want to convert to SQL migration laravel, use this.
How can i import mysql database into laravel 5.2?
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community