Thursday, July 05, 2007

Drop User From a Sybase Database

Denying user access to a database is a fairly simple task. The sp_dropuser stored procedure makes this task possible. However, there are some things you need to ensure beforehand. First, ensure the user doesn't own any objects in the database and has grant privileges or owns the database. Usually, I like to verify the action was performed by performing a quick select on the affected table. Here is the syntax for dropping a user in Sybase.

1> sp_dropuser esofthub
2> go
1> select * from sysusers
2> go

No comments: