When you issue the START VIOLATIONS TABLE statement to create the violations table, the database server uses the set of privileges granted on the target table as a basis for granting privileges on the violations table. The database server follows different rules, however, when it grants each type of privilege.
The following table summarizes the circumstances under which the database server grants each type of privilege on the violations table.
The user cannot create a globally detached index on the violations table even if the user has the Index privilege on the violations table (XPS only).
User has the Select privilege on any other column of the violations table if the user has the Select privilege on the same column in the target table.
(Even with the Update privilege on the informix_tupleid column, however, the user cannot update this SERIAL column.)
User has the Update privilege on any other violations table column if the user has the Update privilege on the same column in the target table.
The following rules apply to ownership of the violations table and privileges on the violations table:
If you do not have the Insert privilege on the violations and diagnostics tables, the database server executes the INSERT, DELETE, or UPDATE statement on the target table provided that you have the necessary privileges on the target table. The database server does not return an error concerning the lack of Insert privilege on the violations and diagnostics tables unless an integrity violation is detected during execution of the INSERT, DELETE, or UPDATE statement.
Similarly, when you issue a SET Database Object Mode statement to set a disabled constraint or disabled unique index to the enabled or filtering mode, and a violations table and diagnostics table exist for the target table, you must have the Insert privilege on the violations and diagnostics tables.
If you do not have the Insert privilege on the violations and diagnostics tables, the database server executes the SET Database Object Mode statement if you have the necessary privileges on the target table. The database server does not return an error concerning the lack of Insert privilege on the violations and diagnostics tables, unless an integrity violation is detected during the execution of the SET Database Object Mode statement.
For example, if user henry was granted the Insert privilege on the target table by both user jill and user albert, then the Insert privilege on the violations table is granted to henry both by jill and by albert.