Run SQL queries from the Administration Console

You can run database queries directly against the PPM database schema from the Administration Console.

Note: You can also run SQL queries from the PPM Workbench. For details, see Run SQL statements from the PPM Workbench.

Run SQL statements from Administration Console

Running SQL statements from the Administration Console is essentially the same as running them from the PPM Workbench. However, from the Administration Console you can run a statement that ends with a semicolon (;).

To run a SQL statement (select statement only) from the Administration Console:

  1. In the Administration Console Actions panel, select Administration Task > SQL Runner.

  2. In the SQL Statement box, type the select statement to run against the PPM database.

    For 10.0.2 and later versions, you can drag the border of the SQL statement box to resize the edit window, or press F11 to enter the full screen edit mode.

  3. Click Run SQL to run the SQL statement.

    For 10.0.2 and later versions, you can also press CTRL+ENTER to run the statement, or press CTRL+DOWN or CTRL+UP to cycle through previously run SQL statements. Click below the SQL statement box to learn about the details.

    The results grid lists the query results in numbered rows.

  4. You can create a dashboard data source and list portlet from the SQL statement. For details, see Create dashboard data source and list portlet from SQL Runner page.

Back to top

Export SQL run results

You can export the SQL run results to a .csv file, a text file, or an Excel file. If you export the results, any sorting and grouping you perform in the Administration Console is discarded. Only the raw results are exported.

To export the results in PPM 10.0.2 and later versions:

  1. Right-click on the results grid.
  2. Click Export from the dropdown menu, and select the file format you want to export the data to.

To export the results in PPM 10.0.1 and earlier versions:

  1. To export the data to a file in comma-separated format, click Open as CSV. To export the data to a text file, click Open as Text.

  2. Click Open, Save, Save as, or Save and open.

Back to top

SQL statement execution details

You can view performance details from the Execution Details section of the SQL Runner page.

Note: For PPM 10.0.2 and later versions, click to view the performance information.

The Execution Details section provides the following information:

Value Description

Database Roundtrip

(for PPM 10.0.2 and later versions)

Server Roundtrip

(for PPM 10.0.1 and earlier versions)

The time spent (in milliseconds) between the PPM Server and the PPM database.

Note: In the PPM Workbench, the Server Roundtrip value represents the time spent between the PPM Workbench client and the PPM Server). In either context, the measure is a good indication of measure network latency.

ResultSet Extraction

The amount of time (in milliseconds) required to extract results from the results set.

SQL Execution

Available in PPM 10.0.1 and earlier versions.

The duration of the SQL run in milliseconds.

Total Time

Available in PPM 10.0.1 and earlier versions.

The total amount of time in milliseconds.

Back to top

See also: