laravel 打印完整sql

DB::connection()->enableQueryLog();  // 开启QueryLog
AppUser::find(1);
dump(DB::getQueryLog());
原文地址:https://www.cnblogs.com/pcx105/p/10616482.html