Running custom queries by using Object Query Language
You can use customized Object Query Language (OQL) queries to analyze the heap dump.
About this task
OQL queries have a similar format to Structured Query
Language (SQL), which is typically used to query relational databases.
OQL represents classes as tables, objects as rows, and fields as columns.
The OQL syntax is as follows:
SELECT * FROM [ INSTANCEOF ] <class_name> [ WHERE <filter_expression> ]
See later topics for more detailed information about OQL
syntax.Procedure
Results
Tip:
You can rerun previous queries by
opening the Navigation History view, then double-clicking an OQL query
from the list. 
You can rerun previous queries by
opening the Navigation History view, then double-clicking an OQL query
from the list. 
What to do next
For many queries, you can select some of objects
in the results area, right-click to display a menu, then click . This action creates an OQL statement that includes
a representation of the selected objects, and the columns that are
shown in the results area. You can paste this OQL statement into an
OQL editor pane, then run it as a new query.Note: This
function is not available in the Web Edition of the product.

) in the toolbar.
) from the toolbar.