You’re not likely to use this method in a finished program, but it’s very useful to call as you’re developing (and/or debugging) a program.
A call to dump_results prints (via STDOUT) the data remaining in the statement handle. If none of the data has been accessed with a call to fetch (which is typically the case), all of the data from the SQL statement is printed.
Example:
$handle->dump_results;