Informix Error -6031: The user does not have SQL permission to SELECT the specified columns.
Cause and resolution
The user does not have SQL permission to SELECT the specified columns.
The user account that is running this program has not been granted SELECT privilege on the current table or on the particular columns that are being selected. A user with DBA privileges for the database should use the SQL statement GRANT to grant the necessary privilege. Then run the program again.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-6031 fires when the running account lacks SELECT privilege on the current table or the specific columns being selected — per the archived catalogue.
- No SELECT privilege granted on the table/columns, per the archived catalogue — the direct, only cause.
Solutions / Resolution
- Have a DBA-privileged user
GRANTthe necessary SELECT privilege, per the archived catalogue, then run the program again.
Examples
N/A
No specific triggering statement is documented beyond the function-level condition described above.
Diagnostic Checks
- Check the account's current SELECT privileges on the table/columns involved.
Related Errors / Related Topics
- -6032 — "The user does not have SQL permission to INSERT rows into the table."
- -6033 — "The user does not have SQL permission to UPDATE the specified columns."
- -6034 — "The user does not have SQL permission to DELETE rows from the table."
Missing SELECT privilege — have a DBA grant it, then retry.