Reputation: 95
I have an hsqldb
, which contains SET DATABASE TRANSACTION CONTROL MVLOCKS
.
I am trying to drop a column:
ALTER TABLE CSUSER DROP COLUMN PASSWORD
But i am having this error:
Error: Error while executing action. Reason: java.sql.SQLIntegrityConstraintViolationException: integrity constraint violation: unique constraint or index violation; SYS_PK_10426 table: CSUSER in statement [ALTER TABLE CSUSER DROP COLUMN PASSWORD]
If i set SET DATABASE TRANSACTION CONTROL LOCKS
, I don't have an error and the column is dropped.
The problem is that i am forced to use MVLOCKS
, and i am not finding any constraint on this column.
Does anyone have an idea?
Upvotes: 1
Views: 787
Reputation: 24372
Use set SET DATABASE TRANSACTION CONTROL LOCKS
, drop the column, then use
SET DATABASE TRANSACTION CONTROL MVLOCKS
.
The reason for the error is the existence of incomplete and uncommitted transactions. You need to commit all transactions.
So before performing a large-scale data and schema change operation, commit any transaction.
Upvotes: 0