Increased precision for status variables Rows_sent and Rows_read from long to longlong
Fixed that status variables 'empty_queries', 'access_denied_errors' and 'lost_connections' are propageted to global status. This should also remove some warnings with VC++ sql/mysqld.cc: Increased precision for status variables Rows_sent and Rows_read from long to longlong sql/sql_class.cc: Increased precision for status variables Rows_sent and Rows_read from long to longlong sql/sql_class.h: Increased precision for status variables Rows_sent and Rows_read from long to longlong Fixed that status variables 'empty_queries', 'access_denied_errors' and 'lost_connections' are propageted to global status.
This commit is contained in:
parent
3edf4dcd5a
commit
cfa0c6ff1d
@ -8052,8 +8052,8 @@ SHOW_VAR status_vars[]= {
|
||||
{"Opened_tables", (char*) offsetof(STATUS_VAR, opened_tables), SHOW_LONG_STATUS},
|
||||
{"Opened_table_definitions", (char*) offsetof(STATUS_VAR, opened_shares), SHOW_LONG_STATUS},
|
||||
{"Prepared_stmt_count", (char*) &show_prepared_stmt_count, SHOW_FUNC},
|
||||
{"Rows_sent", (char*) offsetof(STATUS_VAR, rows_sent), SHOW_LONG_STATUS},
|
||||
{"Rows_read", (char*) offsetof(STATUS_VAR, rows_read), SHOW_LONG_STATUS},
|
||||
{"Rows_sent", (char*) offsetof(STATUS_VAR, rows_sent), SHOW_LONGLONG_STATUS},
|
||||
{"Rows_read", (char*) offsetof(STATUS_VAR, rows_read), SHOW_LONGLONG_STATUS},
|
||||
#ifdef HAVE_QUERY_CACHE
|
||||
{"Qcache_free_blocks", (char*) &query_cache.free_memory_blocks, SHOW_LONG_NOFLUSH},
|
||||
{"Qcache_free_memory", (char*) &query_cache.free_memory, SHOW_LONG_NOFLUSH},
|
||||
|
@ -1190,6 +1190,8 @@ void add_to_status(STATUS_VAR *to_var, STATUS_VAR *from_var)
|
||||
/* Handle the not ulong variables. See end of system_status_var */
|
||||
to_var->bytes_received= from_var->bytes_received;
|
||||
to_var->bytes_sent+= from_var->bytes_sent;
|
||||
to_var->rows_read+= from_var->rows_read;
|
||||
to_var->rows_sent+= from_var->rows_sent;
|
||||
to_var->binlog_bytes_written= from_var->binlog_bytes_written;
|
||||
to_var->cpu_time+= from_var->cpu_time;
|
||||
to_var->busy_time+= from_var->busy_time;
|
||||
@ -1223,6 +1225,8 @@ void add_diff_to_status(STATUS_VAR *to_var, STATUS_VAR *from_var,
|
||||
to_var->bytes_received+= from_var->bytes_received -
|
||||
dec_var->bytes_received;
|
||||
to_var->bytes_sent+= from_var->bytes_sent - dec_var->bytes_sent;
|
||||
to_var->rows_read+= from_var->rows_read - dec_var->rows_read;
|
||||
to_var->rows_sent+= from_var->rows_sent - dec_var->rows_sent;
|
||||
to_var->binlog_bytes_written+= from_var->binlog_bytes_written -
|
||||
dec_var->binlog_bytes_written;
|
||||
to_var->cpu_time+= from_var->cpu_time - dec_var->cpu_time;
|
||||
|
@ -468,8 +468,6 @@ typedef struct system_status_var
|
||||
ulong select_range_count;
|
||||
ulong select_range_check_count;
|
||||
ulong select_scan_count;
|
||||
ulong rows_read;
|
||||
ulong rows_sent;
|
||||
ulong long_query_count;
|
||||
ulong filesort_merge_passes;
|
||||
ulong filesort_range_count;
|
||||
@ -483,6 +481,9 @@ typedef struct system_status_var
|
||||
ulong com_stmt_fetch;
|
||||
ulong com_stmt_reset;
|
||||
ulong com_stmt_close;
|
||||
ulong empty_queries;
|
||||
ulong access_denied_errors;
|
||||
ulong lost_connections;
|
||||
/*
|
||||
Number of statements sent from the client
|
||||
*/
|
||||
@ -493,11 +494,10 @@ typedef struct system_status_var
|
||||
Below 'last_system_status_var' are all variables that cannot be handled
|
||||
automatically by add_to_status()/add_diff_to_status().
|
||||
*/
|
||||
ulong empty_queries;
|
||||
ulong access_denied_errors; /* Can only be 0 or 1 */
|
||||
ulong lost_connections;
|
||||
ulonglong bytes_received;
|
||||
ulonglong bytes_sent;
|
||||
ulonglong rows_read;
|
||||
ulonglong rows_sent;
|
||||
ulonglong binlog_bytes_written;
|
||||
double last_query_cost;
|
||||
double cpu_time, busy_time;
|
||||
|
Loading…
x
Reference in New Issue
Block a user