Allows a Database Owner to impersonate another user.
setuser ["user_name"]
Usage
The Database Owner uses the setuser command to adopt the identity of another user in order to use another user’s database objects. When using Component Integration Services, these objects can be either local or remote.
Component Integration Services processes the setuser command—it does not forward the command to the remote server. Component Integration Services drops all current connections that have been made on behalf of the current user.
The setuser command cannot be executed when a transaction is current.
Permissions that are set on a remote server override permissions set by Component Integration Services. Component Integration Services cannot change permissions of a user on a remote server.
Prior to using the setuser command, the user to be impersonated must have an external login mapped to the remote server. This is set by the sp_addexternlogin system procedure (for more information on sp_addexternlogin, see the Adaptive Server Reference Manual).
See Also
setuser in the Adaptive Server Reference Manual.