Uploaded image for project: 'OpenOLAT'
  1. OpenOLAT
  2. OO-3843

RS: cannot delete an organisation linked to a curriculum

    XMLWordPrintable

    Details

      Description

      2019-01-28 15:23:07,318 [ajp-nio2-8124-exec-5] ERROR OLATRuntimeException - OLAT::ERROR ^%^ N124-E32 ^%^ org.olat.core.logging
      
      https://xyztest.olat.com/auth/AdminSite/0
      Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36 
      
      **RedScreen** org.hibernate.exception.ConstraintViolationException: could not execute statement
      
      <dispatchinfo>
      	<componentinfo>
      		<compname>ffo_main_confirm_delete_organisation</compname>
      		<compclass>org.olat.core.gui.components.form.flexible.impl.FormWrapperContainer</compclass>
      		<extendedinfo>n/a</extendedinfo>
      		<event>
      			<class&gt;org.olat.core.gui.components.form.flexible.impl.FormEvent</class&gt;
      			<command>done</command>
      			<tostring>com:done,org.olat.core.gui.components.form.flexible.impl.FormEvent@2f23a1</tostring>
      		</event>
      	</componentinfo>
      	<controllerinfo>
      		<controllername>org.olat.user.ui.organisation.ConfirmOrganisationDeleteController</controllername>
      		<controllername>org.olat.user.ui.organisation.OrganisationsStructureAdminController</controllername>
      		<controllername>org.olat.user.ui.organisation.OrganisationAdminController</controllername>
      		<controllername>org.olat.admin.SystemAdminMainController</controllername>
      		<controllername>org.olat.core.commons.fullWebApp.BaseFullWebappController</controllername>
      	</controllerinfo>
      </dispatchinfo>
      
      >>> stack of 1.cause::org.olat.core.logging.OLATRuntimeException: org.hibernate.exception.ConstraintViolationException: could not execute statement
      -> at org.olat.core.gui.exception.ExceptionWindowController.<init>(ExceptionWindowController.java:116)
         at org.olat.core.gui.exception.MsgFactory.createMessageChiefController(MsgFactory.java:57)
         at org.olat.core.gui.exception.MsgFactory.createMessageChiefController(MsgFactory.java:46)
         at org.olat.core.gui.components.Window.dispatchRequest(Window.java:589)
         at org.olat.core.gui.components.Window.doDispatchRequest(Window.java:282)
         at org.olat.core.gui.components.AbstractComponent.dispatchRequest(AbstractComponent.java:193)
         at org.olat.dispatcher.AuthenticatedDispatcher.processValidDispatchURI(AuthenticatedDispatcher.java:273)
         at org.olat.dispatcher.AuthenticatedDispatcher.execute(AuthenticatedDispatcher.java:190)
         at org.olat.core.servlets.OpenOLATServlet.executeUserRequest(OpenOLATServlet.java:294)
         at org.olat.core.servlets.OpenOLATServlet.doPost(OpenOLATServlet.java:237)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:661)
      >>> stack of 2.cause::javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not execute statement
      -> at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:154)
         at org.hibernate.internal.ExceptionConverterImpl.convert(ExceptionConverterImpl.java:181)
         at org.hibernate.query.internal.AbstractProducedQuery.list(AbstractProducedQuery.java:1538)
         at org.hibernate.query.Query.getResultList(Query.java:168)
         at org.olat.basesecurity.manager.OrganisationDAO.find(OrganisationDAO.java:178)
         at org.olat.basesecurity.manager.OrganisationServiceImpl.getOrganisations(OrganisationServiceImpl.java:313)
         at org.olat.user.ui.organisation.OrganisationsStructureAdminController.loadModel(OrganisationsStructureAdminController.java:143)
         at org.olat.user.ui.organisation.OrganisationsStructureAdminController.event(OrganisationsStructureAdminController.java:204)
         at org.olat.core.gui.control.DefaultController$1.run(DefaultController.java:250)
         at org.olat.core.logging.activity.ThreadLocalUserActivityLoggerInstaller.runWithUserActivityLogger(ThreadLocalUserActivityLoggerInstaller.java:108)
         at org.olat.core.gui.control.DefaultController.dispatchEvent(DefaultController.java:247)
      >>> stack of 3.cause::org.hibernate.exception.ConstraintViolationException: could not execute statement
      -> at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:112)
         at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
         at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
         at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:99)
         at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.executeUpdate(ResultSetReturnImpl.java:178)
         at org.hibernate.engine.jdbc.batch.internal.NonBatchingBatch.addToBatch(NonBatchingBatch.java:45)
         at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:3491)
         at org.hibernate.persister.entity.AbstractEntityPersister.delete(AbstractEntityPersister.java:3748)
         at org.hibernate.action.internal.EntityDeleteAction.execute(EntityDeleteAction.java:99)
         at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:604)
         at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:478)
      >>> stack of 4.cause::org.postgresql.util.PSQLException: ERROR: update or delete on table "o_org_organisation" violates foreign key constraint "cur_to_org_idx" on table "o_cur_curriculum"
      
      

        Attachments

          Activity

            People

            Assignee:
            srosse Stéphane Rossé
            Reporter:
            srosse Stéphane Rossé
            Tester:
            Mandy Menzel
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours, 50 minutes
                2h 50m