Oracle 5.0 Reference Manual page 1211

Table of Contents

Advertisement

Profiling is controlled by the
Profiling is enabled by setting
mysql>
SET profiling = 1;
displays a list of the most recent statements sent to the server. The size of the list is
SHOW PROFILES
controlled by the
profiling_history_size
The maximum value is 100. Setting the value to 0 has the practical effect of disabling profiling.
All statements are profiled except
those statements in the profile list. Malformed statements are profiled. For example,
is an illegal statement, and a syntax error occurs if you try to execute it, but it will show up in the
profiling list.
displays detailed information about a single statement. Without the
SHOW PROFILE
clause, the output pertains to the most recently executed statement. If
displays information for statement n. The values of
PROFILE
displayed by
SHOW
PROFILES.
The
LIMIT row_count
given,
OFFSET offset
By default,
SHOW PROFILE
the
values displayed by
State
in interpretion for the two statements for some status values (see
Information").
Optional
values may be specified to display specific additional types of information:
type
displays all information
ALL
displays counts for block input and output operations
BLOCK IO
CONTEXT SWITCHES
displays user and system CPU usage times
CPU
displays counts for messages sent and received
IPC
is not currently implemented
MEMORY
displays counts for major and minor page faults
PAGE FAULTS
displays the names of functions from the source code, together with the name and line
SOURCE
number of the file in which the function occurs
displays swap counts
SWAPS
Profiling is enabled per session. When a session ends, its profiling information is lost.
mysql>
SELECT @@profiling;
+-------------+
| @@profiling |
+-------------+
|
0 |
+-------------+
1 row in set (0.00 sec)
mysql>
SET profiling = 1;
Query OK, 0 rows affected (0.00 sec)
mysql>
DROP TABLE IF EXISTS t1;
Query OK, 0 rows affected, 1 warning (0.00 sec)
Syntax
SHOW
[483]
session variable, which has a default value of 0 (OFF).
profiling
[483]
profiling
SHOW PROFILE
clause may be given to limit the output to
may be added to begin the output
displays
and
Status
PROCESSLIST, although there might be some minor differences
SHOW
displays counts for voluntary and involuntary context switches
1191
to 1 or ON:
[483]
session variable, which has a default value of 15.
and
PROFILES, so you will find neither of
SHOW
FOR QUERY n
correspond to the
n
row_count
rows into the full set of rows.
offset
columns. The
Duration
Section 8.10, "Examining Thread
SHOW PROFILING
FOR QUERY n
is included,
SHOW
values
Query_ID
rows. If
is
LIMIT
values are like
Status

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents