Error During Role Index Refresh in SailPoint IdentityIQ : org.hibernate.exception.ConstraintViolationException: could not execute statement

Hi All,

I am encountering an issue when running the Role Index Refresh task in SailPoint IdentityIQ. The task fails with the following exception:

org.hibernate.exception.ConstraintViolationException: could not execute statement

in logs i can these below errors

2025-04-07T11:27:28,734 WARN QuartzScheduler_Worker-3 engine.jdbc.spi.SqlExceptionHelper:137 - SQL Error: 547, SQLState: 23000
2025-04-07T11:27:28,734 ERROR QuartzScheduler_Worker-3 engine.jdbc.spi.SqlExceptionHelper:142 - The DELETE statement conflicted with the REFERENCE constraint “”. The conflict occurred in database “identityiq”, table “identityiq.spt_bundle”, column ‘role_index’.
2025-04-07T11:27:28,734 INFO QuartzScheduler_Worker-3 jdbc.batch.internal.AbstractBatchImpl:208 - HHH000010: On release of batch it still contained JDBC statements
2025-04-07T11:27:28,744 ERROR QuartzScheduler_Worker-3 sailpoint.api.TaskManager:934 - Exception: [org.hibernate.exception.ConstraintViolationException: could not execute statement]

Can anyone advise how to resolve this?

Thanks,
Ranjith M.

Run the IDX job to find and fix if any wrong index references are present and check if this is resolving the issue.

check this Correct IDX rule to detect and fix IDX values - Compass

Hi @iamksatish

As per your suggestion, I ran the IDX task and there were no errors. after running the role index refresh, I encountered the same error that I received previously(org.hibernate.exception.ConstraintViolationException: could not execute statement).

Could you please guide me on how to fix this?

Thanks,
Ranjith M.

Hi @Ranjith25 ,

you should be able to resolve this by deleting all RoleIndexes either via Debug Pages, iiq console or directly on the database.
Subsequently re-run the task to re-calculate the RoleIndexes.

May I ask which version of IIQ you are using atm? Just out of curiosity because we had this issue in earlier times quite frequently but not anymore since we have the brilliant feature “Role Change Propagation”.

Let us know if it helped.

Thanks,
Daniel

Thanks @daniel_neubert . As per your suggestion. I can be able to run the role index refresh!

1 Like