REVOKE CONNECT Statement

Removes a user from the database.

Quick Links:

Go to Parameters

Go to Usage

Go to Standards

Go to Permissions

Syntax

REVOKE CONNECT
   FROM userID [,...]

Parameters

(back to top)

Usage

(back to top)

Use system procedures or CREATE USER and DROP USER statements, not GRANT and REVOKE statements, to add and remove user IDs.

You cannot revoke the connect privileges from a user if he or she owns database objects, such as tables. Attempting to do so with a REVOKE statement, or sp_droplogin or sp_iqdroplogin stored procedure returns an error such as Cannot drop a user that owns tables in runtime system.

Standards

(back to top)

ANSI SQL–compliance level: Transact-SQL extension.

Permissions

(back to top)

Requires the MANAGE ANY USER system privilege.
Note: If revoking CONNECT permissions or revoking table permissions from another user, the target user cannot be connected to the database.
Related reference
GRANT CONNECT Statement