[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-6463) hbm2ddl and Oracle DB: Found: number, expected: boolean

Mark Kempster (JIRA) noreply at atlassian.com
Wed Nov 16 07:26:20 EST 2011


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-6463?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44324#comment-44324 ] 

Mark Kempster commented on HHH-6463:
------------------------------------

Following in the path from this question
http://stackoverflow.com/questions/7081044/hibernate-how-to-set-sql-type-by-annotation

I tried altering the annotation for a boolean column by adding the 'columnDefinition' like so
@Column(columnDefinition="number(1)", name=...)

Setting hibernate to do schema-validation with this persistence.xml property

<property name="hibernate.hbm2ddl.auto" value="validate"/>

was failing with the boolean / number mismatch but now my sample war is deploying properly.


> hbm2ddl and Oracle DB: Found: number, expected: boolean
> -------------------------------------------------------
>
>                 Key: HHH-6463
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-6463
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 4.0.0.Beta1
>            Reporter: Thomas
>
> As described in this forum topic:
> https://forum.hibernate.org/viewtopic.php?f=1&t=1011905&start=0
> Since version 4 Hibernate (hbm2ddl) cannot map a boolean field in a JPA entity to a column with type number(1,0) in Oracle DB.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list