1. Use the tosql() method
$sql = Db::table("user")->where(["id"=>1])->toSql();
echo $sql;
2. Use hyperf's monitoring event to print out the most recent executed statement
3. Go directly to the hyperf log to find
$sql = Db::table("user")->where(["id"=>1])->get();
After summarizing, I personally recommend tosql, which is the easiest.