[hibernate-issues] [Hibernate-JIRA] Created: (HBX-1176) yes_no type is created a char(255) column and not char(1) column

Aviad Lichtenstadt (JIRA) noreply at atlassian.com
Mon Feb 14 08:21:05 EST 2011


yes_no type is created a char(255) column and not char(1) column
----------------------------------------------------------------

                 Key: HBX-1176
                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-1176
             Project: Hibernate Tools
          Issue Type: Bug
          Components: hbm2java
            Reporter: Aviad Lichtenstadt
            Priority: Minor


The following mapping creates a table with a char(255) column instead of char(1) column
This happened to me first with hibernate 3.6 
Using hibernate 3.2.0 it worked fine

I used the following method:
Configuration.generateSchemaCreationScript(dialect);


<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC
        "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
        "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping package="com.test.hibernate.mapping"
	default-lazy="false">
	
	<class name="SimplePojo" table="SIMPLE_POJO" >
		<cache usage="read-write" />
		<id name="id" column="ID">
            <generator class="sequence">
                <param name="sequence">SEQ_POJO</param>
            </generator>
        </id>
        <property name="testBool" type="yes_no"></property>
                 
	</class>
</hibernate-mapping>


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list