Permalink
Browse files

Added a fallback data type for cases when VARCHAR length is over 4000…

… chars.

In such cases the column type will be STRING which is equivalent to
VARCHAR(1,073,741,823).
  • Loading branch information...
1 parent 2f49727 commit 501101a3c0900f2cffbc8a3ff246ababacddef80 @kadishmal kadishmal committed Oct 11, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 hibernate-core/src/main/java/org/hibernate/dialect/CUBRIDDialect.java
@@ -63,7 +63,9 @@ public CUBRIDDialect() {
registerColumnType( Types.TIMESTAMP, "timestamp" );
registerColumnType( Types.TINYINT, "short" );
registerColumnType( Types.VARBINARY, 2000, "bit varying($l)" );
- registerColumnType( Types.VARCHAR, 4000, "varchar($l)" );
+ registerColumnType( Types.VARCHAR, "string" );
+ registerColumnType( Types.VARCHAR, 2000, "varchar($l)" );
+ registerColumnType( Types.VARCHAR, 255, "varchar($l)" );
getDefaultProperties().setProperty(Environment.USE_STREAMS_FOR_BINARY, "true");
getDefaultProperties().setProperty(Environment.STATEMENT_BATCH_SIZE, DEFAULT_BATCH_SIZE);

0 comments on commit 501101a

Please sign in to comment.