
package com.hida.configuration;

import org.dbunit.dataset.datatype.DataType;
import org.dbunit.dataset.datatype.DataTypeException;
import org.dbunit.dataset.datatype.DefaultDataTypeFactory;
import org.hsqldb.types.Types;

/**
 *
 * @author lruffin
 */
public class HsqlDataTypeFactory extends DefaultDataTypeFactory {

	@Override
	public DataType createDataType(int sqlType, String sqlTypeName) throws DataTypeException {
		if (sqlType == Types.BOOLEAN) {
			return DataType.BOOLEAN;
		}
		
		return super.createDataType(sqlType, sqlTypeName);
	}
}

@@ -1,9 +1,8 @@
-%0A
 package 
@@ -220,16 +220,238 @@
 s;%0A%0A/**%0A
+ * There is currently a bug with HSQL where booleans created by HSQL cannot be%0A * read by Hibernate. This class intercepts the creation of entities and changes%0A * the HSQL-accepted booleans to Hibernate-accepted booleans.%0A
  *%0A * @a
@@ -535,17 +535,20 @@
 tory %7B%0A%0A
-%09
+    
 @Overrid
@@ -549,17 +549,20 @@
 verride%0A
-%09
+    
 public D
@@ -644,18 +644,24 @@
 ption %7B%0A
-%09%09
+        
 if (sqlT
@@ -688,11 +688,20 @@
 ) %7B%0A
-%09%09%09
+            
 retu
@@ -725,17 +725,27 @@
 AN;%0A
-%09%09%7D%0A%09%09%0A%09%09
+        %7D%0A%0A        
 retu
@@ -795,9 +795,12 @@
 e);%0A
-%09
+    
 %7D%0A%7D%0A

Add javadocs to HsqlDataTypeFactory