SQL statistics
Home > Select Project > STAT/REPORT > SQL Statistics
Statistics are created based on the SQL execution count, execution time, and waiting time within the active sessions collected by the agent, and a list of top SQLs for the search period is provided. It provides a basis for analyzing frequently performed SQL performance through the average and maximum execution time.
For quick performance analysis, you can search top SQLs for each frequently analyzed category (DB, application, user, host). The main search criteria are as follows:
-
execute count: Execution count of the SQL
-
elapse sum (sec): Total execution time (secs) of the SQL
-
elapse avg (sec): Average execution time (sec) of the SQL. It is the result of elapse sum/execute count.
-
elapse max (sec): Maximum execution time (sec) of the SQL
-
elapse wait (sec): Total waiting time (sec) of the SQL
-
instance: Instance name
The SQL statistics function creates statistics based on the SQL that excludes literal values.
Basic screen guide
-
In Time, select the time and date to view the data. You can select a lookup time after selecting the green button.
-
In Instance, select a target to view the data. You can select multiple instances. To select all instances, click Select all.
-
Select .
The top 50 entries appear in the table.
-
You can filter the desired content by entering a SQL parameter value in the Filter field.
-
The default sort order is execute count. To change the sort order, select a desired criterion from the Sort by list.
-
To download the viewed data as a CSV file, select .
Checking the query-based execution trend
Previewing the query
You can preview the query statement by moving the mouse pointer to the sql column in the search results list.
See details
Select a query statement. The SQL details window appears to display the query statement and SQL plan.
-
View SQL Statistics: You can go to the SQL statistics menu where you can check statistical information related to the SQL query statement.
-
Default Bind: You can bind the part set as a variable in the query sentence to the default value.
-
Reset Bind: You can release the bound default value and check the variable.
-
Formatting: You can improve readability by applying indentation and formatting to a SQL query statement.
-
Plan: To check plan information, enter DB Name, User Name, and Password, and then select .
Filtering the searched results
Adding the filter conditions
You can perform a search by filtering by SQL text, agent name, DB user name, and the like.
-
In the Filter option, select .
-
In Filter key, select a desired filtering criteria.
-
If the value of the selected item is text, you can select any of Includes (blue) and Excludes (red).
-
If the value of the selected item is number, you can select any condition of
==
(equal to),>=
(greater than or equal to), and<=
(less than or equal to).
-
-
In Condition, select a condition.
-
Enter a string or number to match the condition.
-
Select Apply.
-
To add filtering conditions, select Add and then repeat Step 1 to 5. Added conditions are applied based on AND (
&&
). -
To delete some items while adding conditions, select on the right of the filter conditions. To delete all conditions, select Delete All.
-
To quickly delete the conditions applied to the Filter option, select .
-
The default setting is to exclude if
sqlText
contains 'WhaTap'.
Modifying the filter conditions
Click any applied to the Filter option. If the Edit filter window appears, modify any desired items and then select Apply.
Configuring the table columns
You can hide the table header columns or add any of them. You can also change the column order. Select .
-
After configuration, select OK to apply the settings in the table.
-
In the search bar, enter text to search the desired columns. Only the columns that meet the entered text are displayed.
Adding columns
From the list, select the items to add as table header columns. To select all items, select Select All.
Deleting columns
From the list, unselect the columns to delete. Alternatively, select on the right of the item to delete from the list.
Changing the column order
Drag an item to reposition from the list, and then move it to the desired position.
Initializing the configuration
To cancel all changes and reset them, select Reset.