query governor cost limit Option

The term query cost refers to the estimated elapsed time, in seconds, required to execute a query on a specific hardware configuration. Use the query governor cost limit option to specify an upper limit for the time in which a query can run.

If you specify a nonzero, nonnegative value, the query governor disallows execution of any query that has a running length exceeding that value. Specifying 0 (the default) for this option turns off the query governor. In this case, all queries are allowed to run.

If you use sp_configure to change the value of query governor cost limit, the changed value is server-wide. To change the value on a per connection basis, use the SET QUERY_GOVERNOR_COST_LIMIT statement.

query governor cost limit is an advanced option. If you are using the sp_configure system stored procedure to change the setting, you can change query governor cost limit only when show advanced options is set to 1. The setting takes effect immediately (without a server stop and restart).

To set the query governor cost limit option

         

See Also
RECONFIGURE SET QUERY_GOVERNOR_COST_LIMIT
Setting Configuration Options sp_configure

  


(c) 1988-98 Microsoft Corporation. All Rights Reserved.