DROP USER Examples | Teradata Vantage - 17.10 - DROP USER Examples - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - SQL Data Definition Language Syntax and Examples

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
Programming Reference
Publication ID
B035-1144-171K
Language
English (United States)

Example: Dropping User, DBQL Case

Suppose the following DBQL rules are in place.

  • Rule 1: ALL users, any account string, default logging only.
  • Rule 2: ALL users with account string 'finance', object logging.
  • Rule 3: user_1, account string 'marketing', step logging.
  • Rule 4: user_1, account string 'HR', default logging only.

You need to drop user_1. Before you can do so, you must first stop query logging explicitly for user 1 so you can remove Rules 3 and 4.

To do this, submit the following requests in the order indicated.

     END QUERY LOGGING ON user_1 ACCOUNT = ('marketing','HR');
     DROP USER user_1;

Example: Dropping User

This request drops user Jones.

     DROP USER Jones;