Updates the setting details for a specified Query Patroller
query class.
Authorization
You must meet one of the
following requirements:
- Have DBADM authority
- Be an operator whose profile includes CONFIGURATION privilege
with edit authority.
Required connection
None. This command
establishes a database connection.
Command syntax
Note: For information about
entering Query Patroller commands using the command line interface
and general syntax for Query Patroller commands, see
Query Patroller command line support.

>>-UPDATE QUERY_CLASS--query-class-id--USING-------------------->
>--+------------------------------------+----------------------->
'-MAX_QUERIES--max-number-of-queries-'
>--+--------------------------+--------------------------------->
'-MAX_COST--max-query-cost-'
>--+----------------------------+------------------------------><
'-DESCRIPTION--'description'-'
Command parameters
- query-class-id
- Specifies the ID for the query class whose setting details are
to be updated.
- MAX_QUERIES max-number-of-queries
- Specifies the maximum number of queries that can be running simultaneously
for this query class. When this threshold of running queries is reached,
additional queries for this query class will be queued until resources
become available. The value must be greater than or equal to 0 and
less than or equal to the value of MAX_TOTAL_QUERIES specified in
the Query Patroller system settings.
- MAX_COST max-query-cost
- The maximum cost for a single query that this query class will
accept. The value must be greater than 0 and less than or equal to
the value of MAX_TOTAL_COST specified in the Query Patroller System
settings. This value must be distinct for every query class defined
in the system.
- DESCRIPTION description
- Optionally specifies a text description for the query class. This
parameter is nullable.
Examples
The following command updates
query class 8 in the TESTDB database so that it will accept up to
50 queries:
qp -d testdb "UPDATE QUERY_CLASS 8 USING
MAX_QUERIES 50"
Usage notes
- Query classes can be created, removed, or modified while Query
Patroller is started. Creation, changing the maximum query cost,
or removal of a query class will take effect immediately unless there
are queued or running queries. If there are queued or running queries,
including newly submitted queries, the query class changes will take
effect when these complete. If you do not want to wait for all queued
and running queries to complete, a Query Patroller server restart
is required. Updating the maximum number of queries for a query class
always takes effect immediately.