sp_unbindexeclass

Removes the execution class attribute previously associated with an client application, login, stored procedure, or default execution class for the specified scope.

Syntax

sp_unbindexeclass object_name, object_type, scope

Parameters

Examples

Usage

There are additional considerations when using sp_unbindexeclass:
  • The parameters must match an existing entry in the sysattributes system table.

  • If you specify a null value for scope, the SAP ASE server unbinds the object for which the scope is null, if there is one.

  • A null value for scope does not indicate that unbinding should apply to all bound objects.

  • When unbinding a stored procedure from an execution class, you must use the name of the stored procedure owner (user name) for the scope parameter.

  • When unbinding a stored procedure from a user-defined default execution class, all tasks running with user-defined default execution class attributions run with attributes of system-defined default execution class EC2.

  • Stored procedures can be dropped before or after unbinding.

  • A user cannot be dropped from a database if the user owns a stored procedure that is bound to an execution class in that database.

  • Unbind objects of type PR before dropping them from the database.

  • Unbinding fails if the associated engine group has no online engines and active processes are bound to the associated execution class.

  • Due to precedence and scoping rules, the execution class being unbound may or may not have been in effect for the object_name. The object automatically binds itself to another execution class, depending on other binding specifications and precedence and scoping rules. If no other binding is applicable, the object binds to the default execution class. If there is no use-defined default execution class, the object binds to class EC2.

See also isql in the Utility Guide.

Permissions

The permission checks for sp_unbindexeclass differ based on your granular permissions settings.

SettingDescription
Enabled

With granular permissions enabled, you must be a user with manage any execution class privilege.

Disabled

With granular permissions disabled, you must be a user with sa_role.

Auditing

Values in event and extrainfo columns from the sysaudits table are:

InformationValues
Event

38

Audit option

exec_procedure

Command or access audited

Execution of a procedure

Information in extrainfo
  • Roles – Current active roles

  • Keywords or options – NULL

  • Previous value – NULL

  • Current value – NULL

  • Other information – All input parameters

  • Proxy information – Original login name, if set proxy in effect

Related reference
sp_addexeclass
sp_bindexeclass
sp_dropexeclass
sp_showexeclass