[hibernate-issues] [Hibernate-JIRA] Created: (ANN-748) @JoinColumn overrides scale and percision in ManyToOne map..

Andrew C. Oliver (JIRA) noreply at atlassian.com
Thu Jun 5 22:45:33 EDT 2008


@JoinColumn overrides scale and percision in ManyToOne map..
------------------------------------------------------------

                 Key: ANN-748
                 URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-748
             Project: Hibernate Annotations
          Issue Type: Bug
    Affects Versions: 3.4.0.CR1
         Environment: Postgresql but not Hypersonic (haven't tried other DBs, but suspect any real non-java db will replicate)
            Reporter: Andrew C. Oliver
         Attachments: patch.tar.gz

http://forum.hibernate.org/viewtopic.php?t=987527

Since you asked nicely...

This is a patch against your test cases. 

Sorry for the not patch style patch.  It is against the latest download of Annotations (3.4.0.CR1).  I'm on a hotel network that seems to really make SVN angry.  

There are 4 files:
1. Bunny    has many
2. PointyTooth (teeth)
3. IdTest.java, only "testBlownPrecision" is new and "getMappings" includes the rabid bunny and teeth
4. UUIDGenerator - I wouldn't have included it but I couldn't find a decent way to autogenerate 128-bit keys.  (The linked wikipedia article is amusing).

You'll probably want to unzip these into the annotations root directory, then do the svn diff.  Following this you may want to pretty print. 

As the test notes, it will FAIL with the @JoinColumn mapping and succeed if it is commented out.  The failure notes a precision error.  Obviously batching must be disabled to read it.  If you look at the generated table it will have like NUMBER[19].  With JoinColumn commented out it is the expected NUMBER[128].  Thanks to PaaKow Acquah for finding this.

If you want more details, I'll be a TacoMac having another Aventinus...

-- 
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