Informix Error -19800: Role name already exists as a user or role.
Cause and resolution
Role name already exists as a user or role.
You cannot create a role name identical to any user that is known to the system or a user or role that is known to the database. Change the name of the role.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-19800 fires when a CREATE ROLE statement names a role identical to an existing user or
role — per the official guidance.
- A role name matching an existing user known to the system, per the official guidance — the first named case.
- A role name matching an existing user or role known to the database, per the official guidance — the second named case.
Solutions / Resolution
- Change the role name to one that doesn't collide with an existing user or role, per the official guidance.
Examples
A role name colliding with an existing user
CREATE ROLE alice;
-- -19800: alice is already a user known to the system/database
Corrected
CREATE ROLE alice_role;
Diagnostic Checks
- Check
sysusersand existing role names for a collision before creating the role.
Related Errors / Related Topics
- -19801 — "Role name cannot be
." A related role-naming restriction, about reserved words rather than a collision with an existing name. - -19808 — "User name already exists as a rolename in the database." The mirror-image condition, about opening a database as a role name matching a user name.
A role name collides with an existing user or role — choose a different name.