Laravel 4 cannot run whole RAW queries

前端 未结 3 2178
再見小時候
再見小時候 2021-02-14 17:58

I would like to use the DB class of laravel to execute a mysql query but none of the functions provided by Laravel are working.

None of those is working: DB::statment()

3条回答
  •  醉梦人生
    2021-02-14 18:30

    Executing SQL Code just like the one I provided in the question can be executed using

    DB::unprepared( $code );
    

    I hope this helps the people with the same issue i had :D

    Answer found while looking through laravel issues

提交回复
热议问题