The following commands can be used to display or stop the queries running on the database:
SHOW PROCESSES [ LIMIT size ]
Displays the following information about the running queries: id, SQL code, start time, number of output rows, user running the query. The optional LIMIT clause forces the display of the SQL code to be limited to size bytes.
The user issuing the command can always see his/her queries (the sql column).
The user can see the queries of other users who permit that (the s property).
An administrator can see all queries of all users, regardless of their properties.
Processes can also be displayed from the user interface level.
Syntax:
SHOW ALL PROCESSES
Display all processes in all catalogs running in a remote database.
Syntax:
KILL PROCESS process-id
Stops the running query. Can be issued only by adminstartors or the user who launched the process.
This operation can also be performed form the User interface level.