Export (0) Print
Expand All
Expand Minimize

sp_update_category

SQL Server 2000

Changes the name of a category.

Syntax

sp_update_category [@class =] 'class',
    [@name =] 'old_name',
    
[@new_name =] 'new_name'

Arguments

[@class =] 'class'

Is the class of the category to update. class is varchar(8), with no default, and can be one of these values.

Value Description
ALERT Updates an alert category.
JOB Updates a job category.
OPERATOR Updates an operator category.

[@name =] 'old_name'

Is the current name of the category. old_name is sysname, with no default.

[@new_name =] 'new_name'

Is the new name for the category. new_name is sysname, with no default.

Return Code Values

0 (success) or 1 (failure)

Remarks

sp_update_category must be run from the msdb database.

Permissions

Only members of the sysadmin fixed server role or db_owner fixed database role can execute sp_update_category.

Examples

This example renames a job category from Table Archixes to Table Archives.

USE msdb
EXEC sp_update_category 'JOB', 'Table Archixes', 'Table Archives'

See Also

sp_add_category

sp_delete_category

sp_help_category

System Stored Procedures

Show:
© 2014 Microsoft