We have accidentally deleted two custom roles in UiPath Orchestrator. Can those Roles be restored and have the users re-assigned to them?
Accidental deletion of custom roles in UiPath Orchestrator can disrupt normal operations. Fortunately, it is possible to restore these roles and reassign users to them through database manipulation. This article will guide through the process of restoring deleted custom roles and ensuring users are correctly reassigned to them.
Prerequisites
- Access to UiPath Orchestrator database
- Basic knowledge of SQL queries.
Procedure
- Back Up the Database
Before initiating any changes, ensure back up of the database to prevent data loss or any unintentional damage during the process.
- Restore the Deleted Roles
To restore the deleted roles, execute an SQL query to change the `isDeleted` column value from `1` to `0`. Below is a guideline on how to perform this:
- Open your SQL management tool
- Execute the following SQL query to identify the deleted roles:
- SELECT * FROM dbo.Roles WHERE isDeleted = 1;
- Note down the ID(s) of the roles wanted to restore
- Restore the roles by updating the isDeleted column value to 0 with the following query (replace `{Role ID}` with the actual ID of the roles):
UPDATE dbo.Roles
SET isDeleted = 0
WHERE ID = {Role ID};
- Verify the Restoration
After executing the SQL query:
- Log in to the UiPath Orchestrator
- Navigate to the roles section and verify if the deleted roles have been restored
- Check if the users are reassigned to their respective roles.
Conclusion:
By changing the `isDeleted` status from `1` to `0` in the `dbo.Roles` table, restore deleted custom roles in UiPath Orchestrator, retaining the user assignments as well. It is pivotal to always back up the database before making any changes to safeguard against data loss. If done correctly, this method should help in swiftly restoring the deleted custom roles and reinstating the user assignments without any hassles.