laravel/laravel — Issue #186: Run multiple SQL statements from a single string.
Author: daylerees
Created: 2011-11-29 10:22:48+00:00
State: open

As part of a simple setup script, it would be nice to be able to pass the DB object a string containing numerous SQL statements, or even a .sql file.

I tried DB::query() but it was not happy with more than one statement, doing a split on ';' resolves the issue, but is not very pretty.

Something like DB::import($sqlstr); or DB::file(path/to/file.sql); would be really nice.

Asked phillsparks for support and he recommended creating this issue, thanks for all your hard work Taylor :)

Dayle.