WordPress at a glance

get_num_queries() WP 1.0

Retrieve the number of database queries during the WordPress execution.

  • Global. wpdb. $wpdb WordPress database abstraction object.

No Hooks.

Return

Int. Number of database queries.

Usage

get_num_queries();

Code of get_num_queries: wp-includes/functions.php VER 4.9.8

<?php
function get_num_queries() {
	global $wpdb;
	return $wpdb->num_queries;
}

Related Functions

From tag: debug

More from category: SQL

No comments
    Hello, !     Log In . Register