The mysqli_get_client_stats() function returns an associative array containing detailed statistical
data about all client activities on the current process. This includes the number of packets sent, time spent, and
the amount of data transferred.
Practical use: This function is primarily intended for optimization and identifying bottlenecks in communication between PHP and the database. Take a look at the example output of the complete statistics below: