You can assign a set of permissions on individual tables and grant users combinations of these permissions to define their access to a table.
You can use either Sybase Central or Interactive SQL to set permissions. In Interactive SQL, you can use the GRANT statement to grant the following permissions on tables:
To grant permissions on tables or columns (Sybase Central)
Connect to the database as a user with DBA authority.
Click Tables.
Right-click a table and then choose Properties.
Click the Permissions tab and configure the permissions for the table:
Click Apply.
You can also assign permissions from the User Properties or Group Properties window. To assign permissions to multiple users or groups, use the Table Properties window. To assign permissions to multiple tables, use the User Properties window.
To grant permissions on tables or columns (SQL)
Connect to the database as a user with DBA authority.
Execute a GRANT statement to assign the permission.
See GRANT statement.
All table permissions are granted in a very similar fashion. You can grant permission to M_Haneef to delete rows from the table named sample_table as follows:
GRANT DELETE ON sample_table TO M_Haneef; |
You can grant permission to M_Haneef to update the column_1 and column_2 columns only in the table named sample_table as follows:
GRANT UPDATE ( column_1, column_2 ) ON sample_table TO M_Haneef; |
Table permissions are limited in that they generally apply to all the data in a table, although the REFERENCES, SELECT, and UPDATE permissions can be granted to a subset of columns. You can fine-tune user permissions by creating procedures that perform actions on tables, and then granting users the permission to execute the procedure.
Send feedback about this page via email or DocCommentXchange | Copyright © 2008, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.0 |