Drop constraints using CASCADE
Co-Authored-By: William Cekan <wcekan@oath.com>
This commit is contained in:
parent
b35ccc8e37
commit
b5443deab3
|
@ -259,11 +259,6 @@ public class H2Dialect extends Dialect {
|
|||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean supportsIfExistsAfterTableName() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean supportsIfExistsBeforeConstraintName() {
|
||||
return true;
|
||||
|
@ -434,8 +429,25 @@ public class H2Dialect extends Dialect {
|
|||
return false;
|
||||
}
|
||||
|
||||
// Do not drop constraints explicitly, just do this by cascading instead.
|
||||
@Override
|
||||
public boolean supportsIfExistsAfterAlterTable() {
|
||||
public boolean dropConstraints() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getCascadeConstraintsString() {
|
||||
return " CASCADE ";
|
||||
}
|
||||
|
||||
// CASCADE has to be AFTER IF EXISTS in case it's after the tablename
|
||||
@Override
|
||||
public boolean supportsIfExistsAfterTableName() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean supportsIfExistsBeforeTableName() {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue