summaryrefslogtreecommitdiff
path: root/sql/sql_class.h
diff options
context:
space:
mode:
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r--sql/sql_class.h19
1 files changed, 17 insertions, 2 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h
index 3680e28246e..2240236a0e5 100644
--- a/sql/sql_class.h
+++ b/sql/sql_class.h
@@ -1745,8 +1745,15 @@ public:
*/
ha_rows sent_row_count;
- /*
- number of rows we read, sent or not, including in create_sort_index()
+ /**
+ Number of rows read and/or evaluated for a statement. Used for
+ slow log reporting.
+
+ An examined row is defined as a row that is read and/or evaluated
+ according to a statement condition, including in
+ create_sort_index(). Rows may be counted more than once, e.g., a
+ statement including ORDER BY could possibly evaluate the row in
+ filesort() before reading it for e.g. update.
*/
ha_rows examined_row_count;
@@ -2073,6 +2080,11 @@ public:
start_time= user_time= t;
start_utime= utime_after_lock= my_micro_time();
}
+ /*TODO: this will be obsolete when we have support for 64 bit my_time_t */
+ inline bool is_valid_time()
+ {
+ return (start_time < (time_t) MY_TIME_T_MAX);
+ }
void set_time_after_lock() { utime_after_lock= my_micro_time(); }
ulonglong current_utime() { return my_micro_time(); }
inline ulonglong found_rows(void)
@@ -3001,6 +3013,9 @@ public:
void reset();
bool walk(tree_walk_action action, void *walk_action_arg);
+ uint get_size() const { return size; }
+ ulonglong get_max_in_memory_size() const { return max_in_memory_size; }
+
friend int unique_write_to_file(uchar* key, element_count count, Unique *unique);
friend int unique_write_to_ptrs(uchar* key, element_count count, Unique *unique);
};