Jump to content
We've recently updated our Privacy Statement, available here ×

duplicate key value violates unique constraint "jiuserrole_pkey"


Recommended Posts

While executing a report i get following errors:

ERROR AbstractFlushingEventListener - Could not synchronize database state with sessionorg.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch updateCaused by: java.sql.BatchUpdateException: Batch entry 0 insert into JIUserRole (userId, roleId) values (454131, 4) was aborted: ERROR: duplicate key value violates unique constraint "jiuserrole_pkey"  Detail: Key (userid, roleid)=(454131, 4) already exists.  Call getNextException to see other errors in the batch.Caused by: org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "jiuserrole_pkey"  Detail: Key (userid, roleid)=(454131, 4) already exists###ERROR SystemErrorController - Internal server errororg.springframework.dao.DataIntegrityViolationException: Could not execute JDBC batch update; SQL [insert into JIUserRole (userId, roleId) values (?, ?)]; constraint [jiuserrole_pkey]; nested exception is org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch updateCaused by: org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch updateCaused by: java.sql.BatchUpdateException: Batch entry 0 insert into JIUserRole (userId, roleId) values (454131, 4) was aborted: ERROR: duplicate key value violates unique constraint "jiuserrole_pkey"  Detail: Key (userid, roleid)=(454131, 4) already exists.  Call getNextException to see other errors in the batch.Caused by: org.postgresql.util.PSQLException: ERROR: duplicate key value violates unique constraint "jiuserrole_pkey"  Detail: Key (userid, roleid)=(454131, 4) already exists.###ERROR JDBCExceptionReporter - ERROR: duplicate key value violates unique constraint "jiuserrole_pkey"  Detail: Key (userid, roleid)=(454131, 4) already exists.###ERROR JDBCExceptionReporter - Batch entry 0 insert into JIUserRole (userId, roleId) values (454131, 4) was aborted: ERROR: duplicate key value violates unique constraint "jiuserrole_pkey"  Detail: Key (userid, roleid)=(454131, 4) already exists.  Call getNextException to see other errors in the batch.[/code]

Why does jasper try to insert existing user in JIUserRole?

Link to comment
Share on other sites

  • 4 weeks later...
  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...