[hibernate-issues] [Hibernate-JIRA] Commented: (HBX-753) Hibernate Tools generates ID class with Oracle LONG data type

Dan Madoni (JIRA) noreply at atlassian.com
Mon Sep 11 10:36:24 EDT 2006


    [ http://opensource.atlassian.com/projects/hibernate/browse/HBX-753?page=comments#action_24398 ] 

Dan Madoni commented on HBX-753:
--------------------------------

I forgot to mention: I would suggest that the appropriate behavior for this situation is that the tool should either refuse to map the LONG field as part of the PK and return an error, or perhaps instead return a warning before proceeding.

> Hibernate Tools generates ID class with Oracle LONG data type
> -------------------------------------------------------------
>
>          Key: HBX-753
>          URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-753
>      Project: Hibernate Tools
>         Type: Bug

>   Components: reverse-engineer
>  Environment: Hibernate 3.0, Oracle, Hibernate Tools 3.2 beta 7
>     Reporter: Dan Madoni
>     Priority: Minor

>
>
> If an Oracle table PK includes a LONG data type, Hibernate Tools dutifully generates an ID class that includes that LONG field. Later on when you query with the generated  mapped classes, you get an "illegal use of LONG datatype" error (ORA-00997). This can be particularly frustrating since the typical lazy developer (like me) happily goes off and uses these generated classes, then is bewildered to run into an error in code he didn't create or bother to look at since the nice tool did all the work. :)
> The first thing you're going to say, "what kind of moron includes a LONG data type as a PK anyway?" Suffice to say, such PK's exist and people like me have no say in the matter. So considering that some of us are forced between a rock (some zany db administrator) and a hard place (a requirement to use Hibernate), you can hopefully feel our pain. :)

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