hi,

On Tue, 10 Dec 2002 09:10:09 +1100, "Gavin King" <[EMAIL PROTECTED]>
said:
> This has been requested once before, and it would be very 
> trivial to add support for a <generator> subelement of
> <composite-id>. But theres always something very fishy
> about using a generated (ie. synthetic) composite id. It
> really makes no sense. It never even makes sense to have a
> single <key-property> be generated....
> 
> I can't imagine why you would want it....

i'm trying to port some legacy code over to hibernate. the code relies on
a PrimaryKey class for identifying objects. this is not a composite key,
so automatic generation totally makes sense (it really just encapsulates
a String id property). changing this all over the place would be somewhat
painful, that's why i was trying to work around it within the boundaries
of Hibernate.

i would like to know what sort of direction would you recommend, eg
 - replace the PrimaryKey class with String everywhere (-> pain)
 - extend hibernate along the lines you mentioned (sounds good to me, but
 i need further directions)
 - can i just directly use the guts of hibernate to get a new ID?
 - map it some other way (i tried a UserType, didn't really work out)

thanks,
    viktor
-- 
  
  [EMAIL PROTECTED]

-- 
http://fastmail.fm - Faster than the air-speed velocity of an
                      unladen european swallow


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
hibernate-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/hibernate-devel

Reply via email to