![]() |
|
Use the REVOKE FRAGMENT statement to revoke privileges that were granted on individual fragments of a fragmented table. You can use this statement to revoke the Insert, Update, and Delete fragment-level privileges from users.
Use the REVOKE FRAGMENT statement to revoke the Insert, Update, or Delete privilege on one or more fragments of a fragmented table from one or more users.
The REVOKE FRAGMENT statement is only valid for tables that are fragmented according to an expression-based distribution scheme. For an explanation of an expression-based distribution scheme, see Syntax.
You can specify one fragment or a list of fragments in the REVOKE FRAGMENT statement. To specify a fragment, name the dbspace in which the fragment resides.
You do not have to specify a particular fragment or a list of fragments in the REVOKE FRAGMENT statement. If you do not specify any fragments in the statement, the specified users lose the specified privileges on all fragments for which the users currently have those privileges.
You can revoke fragment-level privileges individually or in combination. List the keywords that correspond to the privileges that you are revoking from user. The following table defines each of the fragment-level privileges.
If you specify the ALL keyword in a REVOKE FRAGMENT statement, the specified users lose all fragment-level privileges that they currently have on the specified fragments.
For example, assume that a user currently has the Update privilege on one fragment of a table. If you use the ALL keyword to revoke all current privileges on this fragment from this user, the user loses the Update privilege that he or she had on this fragment.
The examples that follow are based on the customer table. All the examples assume that the customer table is fragmented by expression into three fragments that reside in the dbspaces that are named dbsp1, dbsp2, and dbsp3.
The following statement revokes the Update privilege on the fragment of the customer table in dbsp1 from the user ed:
The following statement revokes the Update and Insert privileges on the fragment of the customer table in dbsp1 from the user susan:
The following statement revokes all privileges currently granted to the user harry on the fragment of the customer table in dbsp1.:
The following statement revokes all privileges currently granted to the user millie on the fragments of the customer table in dbsp1 and dbsp2:
The following statement revokes all privileges currently granted to the users jerome and hilda on the fragment of the customer table in dbsp3:
The following statement revokes all current privileges from the user mel on all fragments for which this user currently has privileges:
Related statements: GRANT FRAGMENT and REVOKE
For a discussion of fragment-level and table-level privileges, see the Informix Guide to Database Design and Implementation.