Privileges
Privileges are the actions that a user is permitted to carry out on a given base table or view.The Privileges are,
SELECT-the Privileges to retrieve data from table
INSERT-the privilege to insert rows into a table
UPDATE-the privilege to delete roes of data from a table
DELETE-the Privileges to delete roes of data from a table
Refferances-the Privileges to reference columns of a named table in integerity constraints
USAGE-the Privileges to use domains,character sets, etc.
Granting Privileges to other users(GRANT)
The GRANT statement is used to grant Privileges to database objects to specifics users.Normally the GRANT statement is used by the owner of a table to give other users access to the data.
GRANT {PrivilegesList | All Privileges}
ON Object name
TO {Authorizationldlist | public }
[WITH GRANT OPTION
PrivilegesList consists of one or more of the following Privileges seperated by commas.
SELECT
DELETE
INSERT [(columnName [,....])]
UPDATE [(columnName [,....])]
REFERENCES [(columnName [,....])] USAGE
For convenience ,the GRANT statement allows the keyword ALL
Privileges to be used to grant all Privileges to a user instead of having to specify the six Privileges
individually.it allows PUBLIC to allow access to be granted to all present and future authorized users
,not just to the user currently known to the DBMS. object Name can be a base table,view,domain,character set etc.WITH GRANT OPTION clause allows the users in Authorizationdlist to pass the Privileges on specifying WITH GRANT OPTION,the users receiving the Privileges may in turn grant it to other users.if this is not specified ,the receiving users will not be able to pass the Privileges on to other users.In this
way ,the owner of the object maintains a high control over who has permission to use the object and
what forms of access are allowed
Subscribe to:
Comments (Atom)
