1DB::enableQueryLog();
2$arr_user = DB::table('users')->select('name', 'email as user_email')->get();
3dd(DB::getQueryLog());
1 DB::connection()->enableQueryLog(); //enable query log
2 $data = $order->all(); //query execute
3 $queries = DB::getQueryLog(); //get query
4 return dd($queries); //show query