Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
Hibernate version: 3
Mapping documents: Sett.hbm.xml, Item.hbm.xml, SettItem.hbm.xml
Code between sessionFactory.openSession() and session.close():
Full stack trace of any exception that occurs:
Name and version of the database you are using: Oracle 9i
The generated SQL (show_sql=true):
Debug level Hibernate log excerpt:
Hello, i have these two classes related in a many-to-many relationship. Sett has many Item and and Item is part of many Sett. This relationshipe is performed byt the table/class SettItem. I need to have this table set as a different class because it has the quantity of Item included in each Sett.
The thing is, Item has the property "length" and the sum of the lengths of all the Items adds up to be the "lenght" of the Sett.
What i'm looking to have is Hibernate sum the lenghts of the Items automatically and store in the length property of the Sett.
Is that possible? How can i go about doing that?
Thanks a lot.
Eduardo