diff --git a/hibernate-core/src/main/java/org/hibernate/dialect/CockroachDialect.java b/hibernate-core/src/main/java/org/hibernate/dialect/CockroachDialect.java index 11e6efd30205..5b1d39163697 100644 --- a/hibernate-core/src/main/java/org/hibernate/dialect/CockroachDialect.java +++ b/hibernate-core/src/main/java/org/hibernate/dialect/CockroachDialect.java @@ -1091,8 +1091,8 @@ public SQLExceptionConversionDelegate buildSQLExceptionConversionDelegate() { return switch (sqlState) { // Serialization Exception case "40001" -> message.contains("WriteTooOldError") - ? new TransactionSerializationException( message, sqlException, sql ); - : null; + ? new TransactionSerializationException( message, sqlException, sql ) + : null; // DEADLOCK DETECTED case "40P01" -> new LockAcquisitionException( message, sqlException, sql ); // LOCK NOT AVAILABLE