Issue Description
Q:
How to create a user account with read-only permission in the Sybase database?
Handling Process
A:
To create a user account with read-only permission in the Sybase 12.0, take the following steps:
1. Log in to the Sybase database as user SA:
solaris#cd /opt/sybase/A*/install
solaris#./isql -Usa �Psa password -SN2000DBServer
2. Add a login user by running the following commands:
1>sp_addlogin login_name,passwrod
2>go
3. Add a user that can query the database by running the following commands:
1>sp_adduser login_name,user_name (Usually, the login_name and user_name are set as the same.)
2>go
4. After you successfully add the two types of users in step 2 and step 3, add the user that can query the database to the corresponding database by running the following commands
1>use BMSDB (Assume that you query the data entries of BSMDB database.)
2>go
5. Add login_name and user_name to the BMSDB database by running the following commands so that read-only permission of BSMDB database is granted to the two types of users.
1>sp_adduser login_name,user_name
2>go
6. Grant the read-only permission of the tables by running the following commands.
1>grant select on tbl_User to user_name
2>go