The SQL Collector for Monitor Server allows you to capture from the Adaptive Server Enterprise Monitor Server any currently executing SQL statements according to your user-defined criteria. Each SQL statement captured is categorized according to suspected levels of performance problem.
The SQL Collector for Monitor Server provides an easy way of viewing and analyzing any SQL statements currently running on the database server. You can specify your own criteria to use in selecting the SQL statements you want to view. Each SQL statement monitored is analyzed to see whether it is potentially problematic so that you can quickly determine which SQL statements may be causing the performance problem.
The SQL Collector window provides a work area for you to add and delete Collectors, storing information on the Collector name and description, number of SQL analyzed, start time, end time, and duration. It offers a way to view the monitored SQL statements. It displays the monitored SQL statement, corresponding query plan and related information such as server process ID (SPID), login name, capture time, and database name. You are able to copy problematic SQL statements to the SQL Optimizer for optimization.
SQL statements collected in Inspector files can be also be analyzed with the SQL Scanner module. Once you have identified potentially problematic SQL statements you can send the SQL to the SQL Optimizer, Index Advisor, the SQL Worksheet, or save them to the SQL Repository.
The SQL Collector for Monitor Server retrieves the SQL statements using the Adaptive Server Enterprise Monitor Server.
The SQL Collector for Monitor Server uses the Adaptive Server Enterprise Monitor Server to capture SQL statements that are currently running on the database. The following items need to be set before using the SQL Collector for Monitor Server:
You must have Adaptive Server 15.0 or later in order to have the Adaptive Server Enterprise Monitor Server.
The Monitor Server must be currently running. It must be configured on the same machine as the database server you want to monitor. With Dsedit, you can PING the remote Monitor Server to ensure that a connection is available from the PC.
The Adaptive Server and Monitor Server are defined in the \sybase\ini\sql.ini file on the client PC. The names in the SQL.INI file must match exactly the name of the Adaptive Server and the Monitor Server on the Database Server.
When adding a new Collector in the Add Collector window, the name for the Monitor Server must match exactly the name of the Monitor Server in the SQL.INI file.
The tempdb system segment should be at least 20 MB.
You must have sa_role privilege assigned to your logon.
ASE Parameter |
Description |
Recommended setting |
event buffers per engine | Specifies the number of events per database server that can be simultaneously monitored. | sp_configure "event buffers per engine", 2000 |
Specifies the maximum size in Kbytes of the SQL text monitored per connection. |
sp_configure "max SQL text monitored", 4096 | |
enable monitoring |
Disables the collection of performance statistics through the monitoring tables. |
sp_configure "enable monitoring", 0 |
Note: For details of how to configure Adaptive Server Enterprise Monitor Server to capture SQL statements, please refer to the Adaptive Server Manuals.
The SQL Collector for Monitor Server data directory is where the data files are created while executing the Inspect function. The data directory path is set in the Preferences window.
To review or change a directory
Click .
Select the Directory Setup tab.
The default setting for this directory is:
C:\Documents and Settings\User\Application Data\Quest Software\Quest SQL Optimizer\DATA
Changes to this directory cannot be made while the SQL Collector for Monitor Server is active.
Note: It is advisable not to change the data directory after you have used this function, as files created during monitoring are kept in this directory.
The SQL Collector window consists of the toolbar, Job List pane, the SQL Text pane, the SQL Information pane and status bar.
The Collector List pane in the SQL Collector window stores information on each Collector. Information includes:
Item | Description |
Collector Name |
The unique Collector name defined by the user. |
Description |
Description of the Collector defined by the user. |
Status |
The current status of the Collector. This column will remain blank until the monitoring process has started. |
Number of SQL |
Total number of SQL statements collected |
Problematic SQL |
Number of Problematic SQL statements collected. |
Complex SQL |
Number of Complex SQL statements collected. |
Simple SQL |
Number of Simple SQL statements collected. |
SQL without Plan |
Number of SQL statements collected without a query plan. |
Creation Date Time |
Date and time of when the Collector was created. |
Start Time |
Start time of when the monitoring process starts. |
End Time |
End time of when the monitoring process ends. |
Server Name |
Monitor Server name. |
Note: The definitions of Problematic, Complex, and Simple SQL statements are provided in the SQL Collector Criteria tab of the Add Collector wizard.
The SQL Text pane displays the monitored SQL statements for a particular Collector. The layout of the SQL statement is unformatted and displayed according to how it is retrieved from the Adaptive Server Enterprise Monitor Server. SQL statements captured from the Monitor Server may consist of transact-SQL and stored procedures. Therefore to identify the SQL statements that you may want to optimize, you should use the SQL Scanner to identify the SELECT, UPDATE, INSERT and DELETE SQL statements that are contained with the stored procedures or transact-SQL .
If the query plan is retrieved for the monitored SQL statement the query plan and other details will be displayed in the SQL Information Pane
The status bar at the bottom of the SQL Collector window shows the following details:
Item | Description |
Data Directory |
Path showing where all the data files produced during monitoring are saved. While monitoring, a progress bar displays to show the monitoring progress. |
Total Collectors |
Total number of Collectors. |
Completed |
Total number of Collectors already monitored. |
Remaining |
Total number of Collectors that have not been monitored. |
Note: The SQL Collector window must remain open during the monitoring process. If you have started the monitoring process, but the scheduled time has not arrived, this window must remain open for the monitoring process to start and run to completion.
© 2024 Quest Software Inc. ALL RIGHTS RESERVED. Feedback Términos de uso Privacidad Cookie Preference Center