Hibernate version:
2.1.4
Full stack trace of any exception that occurs:
Quote:
com.franke.pbs.persistence.PersistenceException: Could not apply configuration
at com.franke.pbs.persistence.HibernatePersistenceManager.setConfiguration(HibernatePersistenceManager.java:143)
at com.franke.pbs.persistence.HibernatePersistenceManager.init(HibernatePersistenceManager.java:152)
at com.franke.pbs.persistence.HibernatePersistenceManager.<init>(HibernatePersistenceManager.java:52)
at com.franke.pbs.persistence.TestHibernatePersistenceManager.setUp(TestHibernatePersistenceManager.java:41)
Caused by: net.sf.hibernate.MappingException: discriminator mapping required for polymorphic persistence
at net.sf.hibernate.persister.EntityPersister.<init>(EntityPersister.java:734)
at net.sf.hibernate.persister.PersisterFactory.createClassPersister(PersisterFactory.java:42)
at net.sf.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:137)
at net.sf.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:768)
at com.franke.pbs.persistence.HibernatePersistenceManager.setConfiguration(HibernatePersistenceManager.java:137)
... 12 more
Name and version of the database you are using:
Oracle 9.2.0.5
I have a object/table mapping which works correctly. Table: ORDER_HEADER, Class: OrderHeader
I have some stored functions that provide me with some (expensive to calculate) additional status information for a record in the ORDER_HEADER table.
I have been trying to use a
<subclass> mapping to define these additional properties, so that they only get loaded (and calculated) when I need them. The problem, obviously, is that I don't have a discriminator column for this situation.
Is there anyway to achieve what I want without resorting to defining the complete mapping again?
Thanks in advance for any info,
David Sykes