Documentation Home
MySQL 5.7 Reference Manual
Related Documentation Download this Manual
PDF (US Ltr) - 39.4Mb
PDF (A4) - 39.4Mb
PDF (RPM) - 38.7Mb
HTML Download (TGZ) - 11.1Mb
HTML Download (Zip) - 11.1Mb
HTML Download (RPM) - 9.8Mb
Man Pages (TGZ) - 213.4Kb
Man Pages (Zip) - 322.6Kb
Info (Gzip) - 3.6Mb
Info (Zip) - 3.6Mb
Excerpts from this Manual

MySQL 5.7 Reference Manual  /  ...  /  The statements_with_sorting and x$statements_with_sorting Views

26.4.3.39 The statements_with_sorting and x$statements_with_sorting Views

These views list normalized statements that have performed sorts. By default, rows are sorted by descending total latency.

The statements_with_sorting and x$statements_with_sorting views have these columns:

  • query

    The normalized statement string.

  • db

    The default database for the statement, or NULL if there is none.

  • exec_count

    The total number of times the statement has executed.

  • total_latency

    The total wait time of timed occurrences of the statement.

  • sort_merge_passes

    The total number of sort merge passes by occurrences of the statement.

  • avg_sort_merges

    The average number of sort merge passes per occurrence of the statement.

  • sorts_using_scans

    The total number of sorts using table scans by occurrences of the statement.

  • sort_using_range

    The total number of sorts using range accesses by occurrences of the statement.

  • rows_sorted

    The total number of rows sorted by occurrences of the statement.

  • avg_rows_sorted

    The average number of rows sorted per occurrence of the statement.

  • first_seen

    The time at which the statement was first seen.

  • last_seen

    The time at which the statement was most recently seen.

  • digest

    The statement digest.


User Comments
User comments in this section are, as the name implies, provided by MySQL users. The MySQL documentation team is not responsible for, nor do they endorse, any of the information provided here.
Sign Up Login You must be logged in to post a comment.