-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 23 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: uh, what? PropertyAccessException: IllegalArgumentException
PostPosted: Tue Aug 01, 2006 4:49 pm 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
Description:
The process of saving an "action batch" entails writing a record to the Batch table, then the Action table, then the Employee and Position tables. With the many-to-one statements disabled in the Batch table (regular properties in their places), the code works fine and writes to all the tables. However, with the m-t-1 turned on, it gets the error below when trying to write a record to the Batch table. Don't know what this error means. Could it be something requiring me to create a separate class for the Action table since the second field of the PK is the same name as the single PK field in the code_wf_action_status table?

Hibernate version: 3

Mapping documents:

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionBatchTable"
table="info_wf_action_batch">

<id name="BatchId" column="batch_id" type="big_decimal">
<generator class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaNextBatchId">
<param name="JndiDbName">java:/workflows</param>
<param name="DbFieldName">next_action_batch_id</param>
</generator>
</id>

<many-to-one name="ActionStatusId" column="action_status_id" not-null="true" update="true" insert="true"
class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable"/>

<many-to-one name="ActionSubstatusId" column="action_substatus_id" not-null="true" update="true" insert="true"
class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionSubstatusTable"/>
<!--
<property name="ActionStatusId" column="action_status_id" update="true" insert="true"/>
<property name="ActionSubstatusId" column="action_substatus_id" update="true" insert="true"/>
-->
<property name="BusinessUnit" column="business_unit" type="string" update="true" insert="true"/>
<property name="CreationDate" column="creation_date" type="timestamp" update="true" insert="true"/>
<property name="DesiredEffectiveDate" column="desired_effective_date" type="timestamp" update="true" insert="true"/>
<property name="EffectiveDate" column="effective_date" type="timestamp" update="true" insert="true"/>
<property name="PortalWorkflowId" column="portal_workflow_id" type="string" update="true" insert="true"/>
<property name="WorkflowId" column="workflow_id" type="big_decimal" update="true" insert="true"/>

<property name="CreatedWho" column="cr_who" type="string" update="true" insert="true"/>
<property name="CreatedWhen" column="cr_when" type="timestamp" update="true" insert="true"/>
<property name="UpdatedWho" column="up_who" type="string" update="true" insert="true"/>
<property name="UpdatedWhen" column="up_when" type="timestamp" update="true" insert="true"/>
</class>

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionTable"
table="info_wf_action">

<composite-id>
<key-property name="BatchId" column="batch_id" type="big_decimal"/>
<key-property name="ActionId" column="action_id" type="big_decimal"/>
</composite-id>

<property name="ActionTypeId" column="action_type_id" type="big_decimal" update="true" insert="true"/>
<property name="ActionTypeDesc" column="action_type_desc" type="string" update="true" insert="true"/>
<property name="Comments" column="comments" type="string" update="true" insert="true"/>

<property name="CreatedWho" column="cr_who" type="string" update="true" insert="true"/>
<property name="CreatedWhen" column="cr_when" type="timestamp" update="true" insert="true"/>
<property name="UpdatedWho" column="up_who" type="string" update="true" insert="true"/>
<property name="UpdatedWhen" column="up_when" type="timestamp" update="true" insert="true"/>

<many-to-one name="BatchId" column="batch_id" cascade="all" not-null="true" update="false" insert="false"
class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionBatchTable"/>

</class>

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable"
table="code_wf_action_status">

<id name="ActionStatusId" column="action_status_id" type="big_decimal">
<generator class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaNextActionStatusId">
<param name="JndiDbName">java:/workflows</param>
<param name="DbFieldName">next_action_status_id</param>
</generator>
</id>

<property name="Description" column="description" type="string" update="true" insert="true"/>
<property name="WorkflowId" column="workflow_id" type="string" update="true" insert="true"/>

<property name="CreatedWho" column="cr_who" type="string" update="true" insert="true"/>
<property name="CreatedWhen" column="cr_when" type="timestamp" update="true" insert="true"/>
<property name="UpdatedWho" column="up_who" type="string" update="true" insert="true"/>
<property name="UpdatedWhen" column="up_when" type="timestamp" update="true" insert="true"/>
</class>

Table being written to:
<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionBatchTable"
table="info_wf_action_batch">

<id name="BatchId" column="batch_id" type="big_decimal">
<generator class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaNextBatchId">
<param name="JndiDbName">java:/workflows</param>
<param name="DbFieldName">next_action_batch_id</param>
</generator>
</id>

<many-to-one name="ActionStatusId" column="action_status_id" not-null="true" update="true" insert="true"
class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable"/>

<many-to-one name="ActionSubstatusId" column="action_substatus_id" not-null="true" update="true" insert="true"
class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionSubstatusTable"/>
<!--
<property name="ActionStatusId" column="action_status_id" update="true" insert="true"/>
<property name="ActionSubstatusId" column="action_substatus_id" update="true" insert="true"/>
-->
<property name="BusinessUnit" column="business_unit" type="string" update="true" insert="true"/>
<property name="CreationDate" column="creation_date" type="timestamp" update="true" insert="true"/>
<property name="DesiredEffectiveDate" column="desired_effective_date" type="timestamp" update="true" insert="true"/>
<property name="EffectiveDate" column="effective_date" type="timestamp" update="true" insert="true"/>
<property name="PortalWorkflowId" column="portal_workflow_id" type="string" update="true" insert="true"/>
<property name="WorkflowId" column="workflow_id" type="big_decimal" update="true" insert="true"/>

<property name="CreatedWho" column="cr_who" type="string" update="true" insert="true"/>
<property name="CreatedWhen" column="cr_when" type="timestamp" update="true" insert="true"/>
<property name="UpdatedWho" column="up_who" type="string" update="true" insert="true"/>
<property name="UpdatedWhen" column="up_when" type="timestamp" update="true" insert="true"/>
</class>

Related Child Table:
<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable"
table="code_wf_action_status">

<id name="ActionStatusId" column="action_status_id" type="big_decimal">
<generator class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaNextActionStatusId">
<param name="JndiDbName">java:/workflows</param>
<param name="DbFieldName">next_action_status_id</param>
</generator>
</id>

<property name="Description" column="description" type="string" update="true" insert="true"/>
<property name="WorkflowId" column="workflow_id" type="string" update="true" insert="true"/>

<property name="CreatedWho" column="cr_who" type="string" update="true" insert="true"/>
<property name="CreatedWhen" column="cr_when" type="timestamp" update="true" insert="true"/>
<property name="UpdatedWho" column="up_who" type="string" update="true" insert="true"/>
<property name="UpdatedWhen" column="up_when" type="timestamp" update="true" insert="true"/>
</class>

Code between sessionFactory.openSession() and session.close():
(too much to show)

Name and version of the database you are using: Sybase 12

Full stack trace of any exception that occurs:

2006-08-01 15:40:19,031 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:031|
WfDbAccess - createActionBatch - attempting to SAVE
2006-08-01 15:40:19,109 DEBUG [org.hibernate.event.def.DefaultSaveOrUpdateEventListener] saving transient instance
2006-08-01 15:40:19,109 DEBUG [us.tx.state.oag.util.HbmNextDbId] HbmWfPaNextBatchId - generate - ENTER
2006-08-01 15:40:19,109 DEBUG [us.tx.state.oag.util.HbmNextDbId] *** INFO: Connection information: workflows
2006-08-01 15:40:19,125 DEBUG [us.tx.state.oag.util.HbmNextDbId] HbmWfPaNextBatchId - generate - EXIT
2006-08-01 15:40:19,125 DEBUG [org.hibernate.event.def.AbstractSaveEventListener] generated identifier: 8.0000000000, using strategy: us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaNextBatchId
2006-08-01 15:40:19,125 DEBUG [org.hibernate.event.def.AbstractSaveEventListener] saving [us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionBatchTable#8.0000000000]
2006-08-01 15:40:19,156 ERROR [org.hibernate.property.BasicPropertyAccessor] IllegalArgumentException in class: us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable, getter method of property: ActionStatusId
2006-08-01 15:40:19,156 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:156|
WfDbAccess - *** ERROR in createActionBatch - SAVE failed
2006-08-01 15:40:19,156 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:156|
WfDbAccess - org.hibernate.PropertyAccessException: IllegalArgumentException occurred calling getter of us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable.ActionStatusId
2006-08-01 15:40:19,171 INFO [STDOUT] org.hibernate.PropertyAccessException: IllegalArgumentException occurred calling getter of us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable.ActionStatusId
at org.hibernate.property.BasicPropertyAccessor$BasicGetter.get(BasicPropertyAccessor.java:119)
at org.hibernate.tuple.AbstractTuplizer.getIdentifier(AbstractTuplizer.java:103)
at org.hibernate.persister.entity.BasicEntityPersister.getIdentifier(BasicEntityPersister.java:2925)
at org.hibernate.persister.entity.BasicEntityPersister.isTransient(BasicEntityPersister.java:2691)
at org.hibernate.engine.ForeignKeys.isTransient(ForeignKeys.java:181)
at org.hibernate.engine.ForeignKeys$Nullifier.isNullifiable(ForeignKeys.java:137)
at org.hibernate.engine.ForeignKeys$Nullifier.nullifyTransientReferences(ForeignKeys.java:69)
at org.hibernate.engine.ForeignKeys$Nullifier.nullifyTransientReferences(ForeignKeys.java:47)
at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:233)
at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:159)
at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:107)
at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId(DefaultSaveOrUpdateEventListener.java:184)
at org.hibernate.event.def.DefaultSaveEventListener.saveWithGeneratedOrRequestedId(DefaultSaveEventListener.java:33)
at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(DefaultSaveOrUpdateEventListener.java:173)
at org.hibernate.event.def.DefaultSaveEventListener.performSaveOrUpdate(DefaultSaveEventListener.java:27)
at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(DefaultSaveOrUpdateEventListener.java:69)
at org.hibernate.impl.SessionImpl.save(SessionImpl.java:445)
at org.hibernate.impl.SessionImpl.save(SessionImpl.java:440)
at us.tx.state.oag.WfPersonnelAction.WfDbAccess.createActionBatch(WfDbAccess.java:193)
at us.tx.state.oag.WfPersonnelAction.WfDbAccess.createNewWorkflow(WfDbAccess.java:328)
at us.tx.state.oag.WfPersonnelAction.PersonnelActionManagement.processCommitBatch(PersonnelActionManagement.java:2455)
at us.tx.state.oag.WfPersonnelAction.PersonnelActionManagement.processAction(PersonnelActionManagement.java:2567)
at us.tx.state.oag.WfPersonnelAction.OagWfPersonnelActionPortlet.processAction(OagWfPersonnelActionPortlet.java:304)
at com.novell.afw.portlet.core.EboPortletContainer.processOperation(EboPortletContainer.java:646)
at com.novell.afw.portlet.core.EboPortletContainer.processOperation(EboPortletContainer.java:549)
at com.novell.afw.portlet.core.EboPortletContainer.performBlockingInteraction(EboPortletContainer.java:192)
at com.novell.afw.portlet.consumer.core.EboPortletConsumerContainer.processOperation(EboPortletConsumerContainer.java:311)
at com.novell.afw.portlet.consumer.core.EboPortletConsumerContainer.performBlockingInteraction(EboPortletConsumerContainer.java:148)
at com.novell.afw.portal.proxy.EboPortletContainerProxy.performBlockingInteraction(EboPortletContainerProxy.java:197)
at com.novell.afw.portal.aggregation.EboPortletProxyHelper.callPortletActionRequest(EboPortletProxyHelper.java:480)
at com.novell.afw.portal.aggregation.EboPortalAggregationControllerImpl.checkAndHandleActionURLType(EboPortalAggregationControllerImpl.java:1987)
at com.novell.afw.portal.aggregation.EboPortalAggregationControllerImpl.initiateRendering(EboPortalAggregationControllerImpl.java:1261)
at com.novell.afw.portal.aggregation.EboPortalAggregationControllerImpl.renderPortalResponse(EboPortalAggregationControllerImpl.java:531)
at com.novell.afw.portal.aggregation.EboPortalAggregationServlet.handlePortalContainerRequest(EboPortalAggregationServlet.java:761)
at com.novell.afw.portal.aggregation.EboPortalAggregationServlet.callService(EboPortalAggregationServlet.java:218)
at com.novell.afw.portal.aggregation.EboPortalAggregationServlet.doGet(EboPortalAggregationServlet.java:90)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at com.novell.afw.portal.xforms.EboXFormClientDetectionFilter.doFilter(EboXFormClientDetectionFilter.java:97)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:66)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:150)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:54)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
at java.lang.Thread.run(Thread.java:534)
Caused by: java.lang.IllegalArgumentException: java.lang.ClassCastException@178c581
at sun.reflect.GeneratedMethodAccessor136.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.hibernate.property.BasicPropertyAccessor$BasicGetter.get(BasicPropertyAccessor.java:105)
... 73 more
2006-08-01 15:40:19,171 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:171|
WfDbAccess - *** ERROR in createNewWorkflow - ROLLing BACK
2006-08-01 15:40:19,171 DEBUG [org.hibernate.transaction.JTATransaction] rollback
2006-08-01 15:40:19,171 DEBUG [org.hibernate.transaction.CacheSynchronization] transaction after completion callback, status: 4
2006-08-01 15:40:19,171 DEBUG [org.hibernate.jdbc.JDBCContext] after transaction completion
2006-08-01 15:40:19,171 DEBUG [org.hibernate.impl.SessionImpl] after transaction completion
2006-08-01 15:40:19,171 DEBUG [org.hibernate.transaction.CacheSynchronization] automatically closing session
2006-08-01 15:40:19,171 DEBUG [org.hibernate.impl.SessionImpl] automatically closing session
2006-08-01 15:40:19,171 DEBUG [org.hibernate.impl.SessionImpl] closing session
2006-08-01 15:40:19,171 DEBUG [org.hibernate.jdbc.AbstractBatcher] closing JDBC connection (open PreparedStatements: 0, globally: 0) (open ResultSets: 0, globally: 0)
2006-08-01 15:40:19,171 DEBUG [org.hibernate.jdbc.JDBCContext] after transaction completion
2006-08-01 15:40:19,171 DEBUG [org.hibernate.impl.SessionImpl] after transaction completion
2006-08-01 15:40:19,171 DEBUG [org.hibernate.transaction.JTATransaction] Rolled back JTA UserTransaction
2006-08-01 15:40:19,171 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:171|
WfDbAccess - createNewWorkflow - EXIT
2006-08-01 15:40:19,171 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:171|
PersonnelActionManagement - processCommitBatch - EXIT
2006-08-01 15:40:19,171 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:171|
PersonnelActionManagement - processAction - EXIT
2006-08-01 15:40:19,171 DEBUG [org.hibernate.impl.SessionImpl] closing session
2006-08-01 15:40:19,171 DEBUG [org.hibernate.impl.SessionImpl] closing session
2006-08-01 15:40:19,171 DEBUG [org.hibernate.impl.SessionImpl] closing session
2006-08-01 15:40:19,171 INFO [STDOUT] PortletLog|1|8/1/06|15:40:19:171|
OagWfPersonnelActionPortlet - processAction - EXIT


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 01, 2006 6:28 pm 
Expert
Expert

Joined: Thu Dec 23, 2004 9:08 pm
Posts: 2008
You haven't included the important java code, but based on the names of your many-to-one entities, the problem is almost certainly that class HbmWfPaActionBatchTable has these methods:
Code:
public double getActionStatusId();
public void setActionStatusId(double actionStatusId);
public double getActionSubStatusId();
public void setActionStatusId(double actionSubStatusId);
It should have these methods (and equivalent member variable and renamed mapping elements):
Code:
public HbmWfPaCodeActionStatusTable getActionStatus();
public void setActionStatus(HbmWfPaCodeActionStatusTable actionStatus);
public HbmWfPaCodeActionSubstatusTable getActionSubStatus();
public void setActionStatus(HbmWfPaCodeActionSubstatusTable actionSubStatus);
BTW, as hibernate is an ORM, it does try to encourage you to forget about the DB when writing java code. Your POJOs should be called something like ActionSubStatus, not HbmWfPaCodeActionSubstatusTable.

_________________
Code tags are your friend. Know them and use them.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 01, 2006 8:56 pm 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
Yea, I'm new to the whole ORM thing and am too literal in my naming conventions.

So, let me get this right. You suggested this:

public HbmWfPaCodeActionStatusTable getActionStatus();
public void setActionStatus(HbmWfPaCodeActionStatusTable actionStatus);
public HbmWfPaCodeActionSubstatusTable getActionSubStatus();
public void setActionStatus(HbmWfPaCodeActionSubstatusTable actionSubStatus);

But the problem is, HbmWfPaCodeActionStatusTable is a "record object" not a field.

Should I create a HbmWfPaCodeActionStatusPk class that represents the primary key of the record? What is wrong with the xxxId method? It is a decimal field...?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 01, 2006 10:16 pm 
Expert
Expert

Joined: Thu Dec 23, 2004 9:08 pm
Posts: 2008
No. You want to deal with the object, not the id. That's what's going wrong. You've specified
Code:
<many-to-one name="ActionStatusId" column="action_status_id" not-null="true" update="true" insert="true"
class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaCodeActionStatusTable"/>
Therefore hibernate knows that each ActionStatusId property is an instance of the HbmWfPaCodeActionStatusTable class. This is what you've told hibernate, but you've told your POJO that it's a BigDecimal (or double, or whatever you've define the ID to be). Hence the exception. You must deal with the class, not IDs to the class. The correct action is to rename your ActionStatusId property to ActionStatus, and change its type to HbmWfPaCodeActionStatusTable (or whatever you rename it to).

_________________
Code tags are your friend. Know them and use them.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 10:25 am 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
Oh! That makes sense then. Ok, then explain this, if you would: with a PK in the Batch table of a single bigdecimal, linking back to it is easy:

<many-to-one name="BatchId" column="batch_id" cascade="all" not-null="true" update="false" insert="false"/>

Though I'm at a loss as to how Hibernate is supposed to gleen that this link goes back to the Batch table. Is it doing it based on the name of the field?

Since BatchId is the first field of the same binary key in 3 other tables, a la:

<composite-id>
<key-property name="BatchId" column="batch_id" type="big_decimal"/>
<key-property name="ActionId" column="action_id" type="big_decimal"/>
</composite-id>

I want these other tables to link back to the action table who has original instance of the BatchId/ActionId combination. I've gotten this to work:

<many-to-one name="BatchId" not-null="true" update="false" insert="true">
<column name="BatchId"/>
<column name="ActionId"/>
</many-to-one>

But that doesn't make much sense to me. In my mind it should read name="TablePk", but when I do that, Hibernate complains that the field TablePk cannot be found. Which is very confusing since I'm describing a binary relationship to go with the binary key! The signatures table is even more complex:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

<hibernate-mapping default-cascade="none" default-access="property" auto-import="true">

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaSignaturesTable"
table="info_wf_action_signatures">

<composite-id>
<key-property name="BatchId" column="batch_id" type="big_decimal"/>
<key-property name="ActionId" column="action_id" type="big_decimal"/>
<key-property name="SignatureId" column="signature_id" type="big_decimal"/>
<key-property name="SignatureDate" column="signature_date" type="timestamp"/>
</composite-id>

<many-to-one name="BatchId" column="batch_id" not-null="true" update="true" insert="true"/>

<many-to-one name="ActionPk" not-null="true" update="true" insert="true">
<column name="BatchId"/>
<column name="ActionId"/>
</many-to-one>

<many-to-one name="SignatureId" column="signature_id" not-null="true" update="true" insert="true"/>

<property name="Comments" column="comments" type="string" update="true" insert="true"/>
<property name="Email" column="email" type="string" update="true" insert="true"/>
<property name="EmplId" column="emplid" type="string" update="true" insert="true"/>
<property name="EmployeeNameFirst" column="emp_name_first" type="string" update="true" insert="true"/>
<property name="EmployeeNameLast" column="emp_name_last" type="string" update="true" insert="true"/>
<property name="ResultFlag" column="result_flag" type="string" update="true" insert="true"/>

</class>

</hibernate-mapping>


Top
 Profile  
 
 Post subject: DB Schema in Question
PostPosted: Wed Aug 02, 2006 10:34 am 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
Here's the Schema...perhaps it will clarify why I'm having trouble mapping this w/Hibernate.

create rule r_s_mgr_super_flag as
@column in ('N','M','S') and @column = upper(@column)
go

execute sp_addtype b_flag, 'int', 'not null'
go

execute sp_bindefault 'd_b_flag', 'b_flag'
go

execute sp_addtype bd_salary, 'dec(14,4)', 'not null'
go

execute sp_addtype dc_identifier, 'numeric(18,0)', 'not null'
go

execute sp_addtype dc_identifier_opt, 'numeric(18,0)', 'null'
go

execute sp_addtype dt_last_update, 'datetime', 'not null'
go

execute sp_bindefault 'd_dt_last_update', 'dt_last_update'
go

execute sp_addtype dt_last_update_opt, 'datetime', 'null'
go

execute sp_addtype s_agency_code, 'char(4)', 'not null'
go

execute sp_addtype s_agency_code_opt, 'char(4)', 'null'
go

execute sp_addtype s_app_code, 'char(32)', 'not null'
go

execute sp_addtype s_app_resource, 'varchar(2048)', 'not null'
go

execute sp_addtype s_area_code, 'char(5)', 'null'
go

execute sp_addtype s_business_unit, 'char(4)', 'not null'
go

execute sp_addtype s_business_unit_opt, 'char(4)', 'null'
go

execute sp_addtype s_city, 'varchar(25)', 'not null'
go

execute sp_addtype s_comment, 'varchar(254)', 'not null'
go

execute sp_addtype s_country_code, 'char(3)', 'null'
go

execute sp_addtype s_county_code, 'char(13)', 'null'
go

execute sp_addtype s_dept_id, 'varchar(10)', 'not null'
go

execute sp_addtype s_dept_id_opt, 'varchar(10)', 'null'
go

execute sp_addtype s_desc_long, 'varchar(60)', 'not null'
go

execute sp_addtype s_desc_long_opt, 'varchar(60)', 'null'
go

execute sp_addtype s_desc_short, 'varchar(30)', 'not null'
go

execute sp_addtype s_desc_short_opt, 'varchar(30)', 'null'
go

execute sp_addtype s_ed_cn, 'varchar(64)', 'not null'
go

execute sp_addtype s_ed_cn_opt, 'varchar(64)', 'null'
go

execute sp_addtype s_ed_department, 'varchar(64)', 'null'
go

execute sp_addtype s_ed_given_name, 'varchar(32)', 'not null'
go

execute sp_addtype s_ed_sur_name, 'varchar(128)', 'not null'
go

execute sp_addtype s_ed_title, 'varchar(64)', 'null'
go

execute sp_addtype s_email, 'varchar(100)', 'not null'
go

execute sp_addtype s_email_opt, 'varchar(100)', 'null'
go

execute sp_addtype s_emplid, 'char(11)', 'not null'
go

execute sp_addtype s_emplid_opt, 'char(11)', 'null'
go

execute sp_addtype s_login_id, 'char(11)', 'not null'
go

execute sp_addtype s_mgr_super_flag, 'char(1)', 'null'
go

execute sp_bindrule 'r_s_mgr_super_flag', s_mgr_super_flag
go

execute sp_addtype s_org_code, 'char(1)', 'not null'
go

execute sp_addtype s_org_code_opt, 'char(1)', 'null'
go

execute sp_addtype s_pay_group, 'char(3)', 'not null'
go

execute sp_addtype s_pca, 'char(3)', 'not null'
go

execute sp_addtype s_phone_num, 'varchar(20)', 'not null'
go

execute sp_addtype s_phone_num_opt, 'varchar(20)', 'null'
go

execute sp_addtype s_position, 'char(8)', 'not null'
go

execute sp_addtype s_postal_code, 'varchar(15)', 'not null'
go

execute sp_addtype s_ssn, 'char(9)', 'not null'
go

execute sp_addtype s_ssn_opt, 'char(9)', 'null'
go

execute sp_addtype s_state, 'char(6)', 'not null'
go

execute sp_addtype s_state_code, 'char(6)', 'not null'
go

execute sp_addtype s_user_login, 'char(12)', 'not null'
go

execute sp_addtype s_who, 'varchar(20)', 'not null'
go

create table code_wf_action_signatures (
signature_id dc_identifier not null,
description s_desc_long not null,
workflow_id dc_identifier not null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table code_wf_action_signatures
add constraint pk_code_wf_action_signatures primary key (signature_id)
go

create table code_wf_action_status (
action_status_id dc_identifier not null,
description s_desc_long not null,
workflow_id dc_identifier not null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table code_wf_action_status
add constraint pk_code_action_status primary key (action_status_id)
go

create table code_wf_action_substatus (
action_substatus_id dc_identifier not null,
description s_desc_long not null,
workflow_id dc_identifier not null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table code_wf_action_substatus
add constraint pk_code_action_substatus primary key (action_substatus_id)
go

create table code_wf_action_type (
action_type_id dc_identifier not null,
description s_desc_long not null,
enabled b_flag not null,
workflow_id dc_identifier not null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table code_wf_action_type
add constraint pk_code_action_type primary key (action_type_id)
go

create table code_wf_attachment_type (
attachment_type_id dc_identifier not null,
description s_desc_long not null,
workflow_id dc_identifier not null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table code_wf_attachment_type
add constraint pk_code_action_status primary key (attachment_type_id)
go

create table code_workflows (
workflow_id dc_identifier not null,
description s_desc_long not null,
date_effective datetime null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table code_workflows
add constraint pk_code_action_status primary key (workflow_id)
go

create table info_wf_action (
batch_id dc_identifier not null,
action_id dc_identifier not null,
action_type_id dc_identifier not null,
action_type_desc s_desc_short_opt null,
comments text not null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table info_wf_action
add constraint pk_info_wf_action primary key (batch_id, action_id)
go

create table info_wf_action_batch (
batch_id dc_identifier not null,
action_status_id dc_identifier not null,
action_substatus_id dc_identifier not null,
business_unit char(10) null,
creation_date datetime not null,
desired_effective_date datetime null,
effective_date datetime null,
portal_workflow_id s_desc_long not null,
workflow_id dc_identifier not null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table info_wf_action_batch
add constraint pk_info_wf_action_batch primary key (batch_id)
go

create table info_wf_action_docs (
batch_id dc_identifier not null,
attachment_id dc_identifier not null,
attachment_type_id dc_identifier not null,
mime_type s_desc_short not null,
commentary text null,
doc_fs_name s_desc_long not null,
document_data image not null,
cr_who s_who not null,
cr_when dt_last_update not null
)
go

alter table info_wf_action_docs
add constraint pk_info_wf_action_batch primary key (batch_id, attachment_id)
go

create table info_wf_action_employee (
batch_id dc_identifier not null,
action_id dc_identifier not null,
emp_deptid s_dept_id not null,
emp_dept_name s_desc_long not null,
emp_email s_email_opt null,
emplid s_emplid not null,
emp_name_first s_desc_short not null,
emp_name_last s_desc_short_opt not null,
emp_name_preferred s_desc_short_opt null,
emp_phone_work s_phone_num_opt null,
emp_ssn s_ssn_opt not null,
employment_date datetime not null,
last_eval_date datetime null,
last_hire_date datetime null,
last_promotion_date datetime null,
last_work_date datetime null,
lwop_start_date datetime null,
lwop_end_date datetime null,
mail_code char(10) null,
mgr_deptid s_dept_id null,
mgr_dept_name s_desc_long not null,
mgr_email s_email_opt null,
mgr_emplid s_emplid_opt not null,
mgr_name_first s_desc_short not null,
mgr_name_last s_desc_short not null,
mgr_name_preferred s_desc_short_opt null,
mgr_phone_work s_phone_num_opt null,
termination_date datetime null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table info_wf_action_employee
add constraint pk_info_wf_pa_employee primary key (batch_id, action_id)
go

create table info_wf_action_position (
batch_id dc_identifier not null,
action_id dc_identifier not null,
to_bsns_unit s_business_unit null,
to_budget_amendment varchar(30) null,
to_class_number s_desc_short_opt null,
to_class_title s_desc_short_opt null,
to_eeo_function s_desc_short_opt null,
to_flsa_number s_desc_short_opt null,
to_manager_type s_mgr_super_flag null
constraint ckc_to_manager_type_info_wf_ check (to_manager_type is null or (to_manager_type in ('M','S','U','N'))),
to_office_cube_available char(1) null,
to_org_code1 s_org_code null,
to_org_code_desc s_desc_long_opt null,
to_org_code2 s_org_code_opt null,
to_org_code3 s_org_code_opt null,
to_org_code4 s_org_code_opt null,
to_org_full s_desc_short_opt null,
to_pay_group s_pay_group null,
to_pay_grade s_pay_group not null,
to_position_number s_position null,
to_pca s_pca null,
to_salary_annually bd_salary null,
to_salary_monthly bd_salary null,
to_weekly_hours dec(5,2) null,
from_bsns_unit s_business_unit null,
from_class_number s_desc_short_opt null,
from_class_title s_desc_short_opt null,
from_eeo_function s_desc_short_opt null,
from_flsa_number s_desc_short_opt null,
from_manager_type s_mgr_super_flag null
constraint ckc_from_manager_type_info_wf_ check (from_manager_type is null or (from_manager_type in ('M','S','U','N'))),
from_office_cube_available char(1) null,
from_org_code1 s_org_code null,
from_org_code_desc s_desc_long_opt null,
from_org_full s_desc_short_opt null,
from_pay_group s_pay_group null,
from_pay_grade s_pay_group not null,
from_position_number s_position null,
from_pca s_pca null,
from_salary_annually bd_salary null,
from_salary_monthly bd_salary null,
from_weekly_hours dec(5,2) null,
cr_who s_who not null,
cr_when dt_last_update not null,
up_who s_who not null,
up_when dt_last_update not null
)
go

alter table info_wf_action_position
add constraint pk_info_wf_pa_position_info primary key (batch_id, action_id)
go

create table info_wf_action_signatures (
batch_id dc_identifier not null,
action_id dc_identifier not null,
signature_id dc_identifier not null,
signature_date datetime not null,
comments text not null,
email s_email_opt not null,
emplid s_emplid not null,
emp_name_first s_desc_short not null,
emp_name_last s_desc_short_opt not null,
result_flag char(1) default '?' not null
)
go

alter table info_wf_action_signatures
add constraint pk_info_wf_signatures primary key (batch_id, action_id, signature_id, signature_date)
go

create table sys_next_ids (
next_action_batch_id dc_identifier not null,
next_action_status_id dc_identifier not null,
next_action_substatus_id dc_identifier not null,
next_action_signature_id dc_identifier not null,
next_action_type_id dc_identifier not null,
next_workflow_id dc_identifier not null,
next_attachment_id dc_identifier not null
)
go

create table sys_parameters (
key_name varchar(80) not null,
key_value varchar(2048) not null
)
go

alter table sys_parameters
add constraint pk_sys_parameters primary key (key_name)
go

alter table code_wf_action_signatures
add constraint fk_cw_cwfasig_wfid foreign key (workflow_id)
references code_workflows (workflow_id)
go

alter table code_wf_action_status
add constraint fk_cw_cwfas_wfid foreign key (workflow_id)
references code_workflows (workflow_id)
go

alter table code_wf_action_substatus
add constraint fk_cw_cwfass_wfid foreign key (workflow_id)
references code_workflows (workflow_id)
go

alter table code_wf_action_type
add constraint fk_cw_cwfat_wfid foreign key (workflow_id)
references code_workflows (workflow_id)
go

alter table code_wf_attachment_type
add constraint fk_cw_cwfatt_wfid foreign key (workflow_id)
references code_workflows (workflow_id)
go

alter table info_wf_action
add constraint fk_cwat_iwpa_action_type_id foreign key (action_type_id)
references code_wf_action_type (action_type_id)
go

alter table info_wf_action
add constraint fk_iwab_iwa_batch_id foreign key (batch_id)
references info_wf_action_batch (batch_id)
go

alter table info_wf_action_batch
add constraint fk_cw_wfab_wid foreign key (workflow_id)
references code_workflows (workflow_id)
go

alter table info_wf_action_batch
add constraint fk_cwas_iwab_status_id foreign key (action_status_id)
references code_wf_action_status (action_status_id)
go

alter table info_wf_action_batch
add constraint fk_cwass_iwab_ssid foreign key (action_substatus_id)
references code_wf_action_substatus (action_substatus_id)
go

alter table info_wf_action_docs
add constraint fk_cwfat_iwfad_att_type_id foreign key (attachment_type_id)
references code_wf_attachment_type (attachment_type_id)
go

alter table info_wf_action_docs
add constraint fk_wfab_iwfad_batch_id foreign key (batch_id)
references info_wf_action_batch (batch_id)
go

alter table info_wf_action_employee
add constraint fk_iwa_iwae_pk foreign key (batch_id, action_id)
references info_wf_action (batch_id, action_id)
go

alter table info_wf_action_position
add constraint fk_iwa_iwap_pk foreign key (batch_id, action_id)
references info_wf_action (batch_id, action_id)
go

alter table info_wf_action_signatures
add constraint fk_cwas_iwpa_sig_id foreign key (signature_id)
references code_wf_action_signatures (signature_id)
go

alter table info_wf_action_signatures
add constraint fk_iwa_iwas_pk foreign key (batch_id, action_id)
references info_wf_action (batch_id, action_id)
go


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 10:41 am 
Expert
Expert

Joined: Tue Apr 25, 2006 12:04 pm
Posts: 260
Doesnt <many-to-one> elements require class attribute.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 10:47 am 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
That's part of my confusion. If so, exactly what kind of class should it have? A unique class representing the multi-part PK for the table in question or the class that represents the entire record?

I tried the latter and I get getter exceptions (see first post in this thread).


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 11:08 am 
Expert
Expert

Joined: Tue Apr 25, 2006 12:04 pm
Posts: 260
Within class attribute of <many-to-one> element I include the mapping class to which this relation is being enabled.

Code:
<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaSignaturesTable" table="info_wf_action_signatures">
...
   <many-to-one name="batchObject" not-null="true" update="false" insert="true" class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionBatchTable">
      <column name="BatchId"/>
      <column name="ActionId"/>
   </many-to-one>
...
</class>


Your Java class for the above example would be

Code:
// respective import statements
// ...
public class HbmWfPaSignaturesTable {
   private HbmWfPaActionBatchTable batchObject;

   public void setBatchObject( HbmWfPaActionBatchTable bObject ) {
      this.batchObject = bObject;
   }

   public HbmWfPaActionBatchTable getBatchObject () {
      return this.batchObject;
   }
}


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 12:03 pm 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
I've done as suggested. I GUESS things are working. Except...and error message that makes NO kind of sense.

Also, do I infer correctly, that if a field that is part of a multi-part key (as in Signatures table below) is part of m-2-1, it doesn't get listed as a property? But SignatureDate below is part of the PK, but not part of m-2-1 so it has to be listed...right?

Mapping Documents

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

<hibernate-mapping default-cascade="none" default-access="property" auto-import="true">

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionTable"
table="info_wf_action">

<composite-id>
<key-property name="BatchId" column="batch_id" type="big_decimal"/>
<key-property name="ActionId" column="action_id" type="big_decimal"/>
</composite-id>

<many-to-one name="BatchId" column="batch_id" not-null="true" update="false" insert="false"/>

<property name="ActionId" column="action_id" type="big_decimal" update="false" insert="true"/>

<property name="ActionTypeId" column="action_type_id" type="big_decimal" update="true" insert="true"/>
<property name="ActionTypeDesc" column="action_type_desc" type="string" update="true" insert="true"/>
<property name="Comments" column="comments" type="string" update="true" insert="true"/>

<property name="CreatedWho" column="cr_who" type="string" update="true" insert="true"/>
<property name="CreatedWhen" column="cr_when" type="timestamp" update="true" insert="true"/>
<property name="UpdatedWho" column="up_who" type="string" update="true" insert="true"/>
<property name="UpdatedWhen" column="up_when" type="timestamp" update="true" insert="true"/>

</class>

</hibernate-mapping>

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

<hibernate-mapping default-cascade="none" default-access="property" auto-import="true">

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaSignaturesTable"
table="info_wf_action_signatures">

<composite-id>
<key-property name="BatchId" column="batch_id" type="big_decimal"/>
<key-property name="ActionId" column="action_id" type="big_decimal"/>
<key-property name="SignatureId" column="signature_id" type="big_decimal"/>
<key-property name="SignatureDate" column="signature_date" type="timestamp"/>
</composite-id>

<!-- many-to-one name="BatchId" column="batch_id" not-null="true" update="true" insert="true"/ -->

<many-to-one name="ActionPk" not-null="true" update="false" insert="true"
class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionTable">
<column name="BatchId"/>
<column name="ActionId"/>
</many-to-one>

<many-to-one name="SignatureId" column="signature_id" update="false" insert="true"/>

<property name="SignatureDate" column="signature_date" type="timestamp" update="false" insert="true"/>

<property name="Comments" column="comments" type="string" update="false" insert="true"/>
<property name="Email" column="email" type="string" update="false" insert="true"/>
<property name="EmplId" column="emplid" type="string" update="false" insert="true"/>
<property name="EmployeeNameFirst" column="emp_name_first" type="string" update="false" insert="true"/>
<property name="EmployeeNameLast" column="emp_name_last" type="string" update="false" insert="true"/>
<property name="ResultFlag" column="result_flag" type="string" update="false" insert="true"/>

</class>

</hibernate-mapping>

Error
2006-08-02 10:58:23,250 INFO [org.hibernate.cfg.Configuration] Found mapping documents in jar: us/tx/state/oag/WfPersonnelAction/hbm/HbmWfPaSignaturesTable.hbm.xml
2006-08-02 10:58:23,265 DEBUG [org.hibernate.util.DTDEntityResolver] trying to locate http://hibernate.sourceforge.net/hibern ... ng-3.0.dtd in classpath under org/hibernate/
2006-08-02 10:58:23,265 DEBUG [org.hibernate.util.DTDEntityResolver] found http://hibernate.sourceforge.net/hibern ... ng-3.0.dtd in classpath
2006-08-02 10:58:23,265 INFO [org.hibernate.cfg.HbmBinder] Mapping class: us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaSignaturesTable -> info_wf_action_signatures
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: BatchId -> batch_id
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: ActionId -> action_id
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: SignatureId -> signature_id
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: SignatureDate -> signature_date
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: ActionPk -> BatchId, ActionId
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: SignatureId -> signature_id
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: SignatureDate -> signature_date
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: Comments -> comments
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: Email -> email
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: EmplId -> emplid
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: EmployeeNameFirst -> emp_name_first
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: EmployeeNameLast -> emp_name_last
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: ResultFlag -> result_flag
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.Configuration] Preparing to build session factory with filters : {}
2006-08-02 10:58:23,265 INFO [org.hibernate.cfg.Configuration] processing extends queue
2006-08-02 10:58:23,265 INFO [org.hibernate.cfg.Configuration] processing collection mappings
2006-08-02 10:58:23,265 INFO [org.hibernate.cfg.Configuration] processing association property references
2006-08-02 10:58:23,265 INFO [org.hibernate.cfg.Configuration] processing foreign key constraints
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.Configuration] resolving reference to class: us.tx.state.oag.ApplicationSecurity.hbm.HbmAppSecCodeOwnerType
2006-08-02 10:58:23,265 DEBUG [org.hibernate.cfg.Configuration] resolving reference to class: java.math.BigDecimal
2006-08-02 10:58:23,265 ERROR [org.jboss.hibernate.jmx.Hibernate] Starting failed jboss.jca:service=HbmWorkflows
org.hibernate.MappingException: An association from the table info_wf_action refers to an unmapped class: java.math.BigDecimal
at org.hibernate.cfg.Configuration.secondPassCompileForeignKeys(Configuration.java:945)
at org.hibernate.cfg.Configuration.secondPassCompile(Configuration.java:898)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1049)
at org.jboss.hibernate.jmx.Hibernate.buildSessionFactory(Hibernate.java:611)
at org.jboss.hibernate.jmx.Hibernate.startService(Hibernate.java:578)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:272)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:222)
at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:891)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:416)
at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:261)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:964)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:956)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:956)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:775)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:738)
at sun.reflect.GeneratedMethodAccessor48.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:122)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:131)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy8.deploy(Unknown Source)
at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:305)
at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:481)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:204)
at org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:277)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:272)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:222)
at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:891)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:416)
at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:261)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:964)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:775)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:738)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:722)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:122)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:131)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy5.deploy(Unknown Source)
at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:413)
at org.jboss.system.server.ServerImpl.start(ServerImpl.java:310)
at org.jboss.Main.boot(Main.java:162)
at org.jboss.Main$1.run(Main.java:423)
at java.lang.Thread.run(Thread.java:534)
2006-08-02 10:58:23,531 WARN [org.jboss.system.ServiceController] Problem starting service jboss.jca:service=HbmWorkflows
org.hibernate.MappingException: An association from the table info_wf_action refers to an unmapped class: java.math.BigDecimal
at org.hibernate.cfg.Configuration.secondPassCompileForeignKeys(Configuration.java:945)
at org.hibernate.cfg.Configuration.secondPassCompile(Configuration.java:898)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1049)
at org.jboss.hibernate.jmx.Hibernate.buildSessionFactory(Hibernate.java:611)
at org.jboss.hibernate.jmx.Hibernate.startService(Hibernate.java:578)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:272)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:222)
at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:891)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:416)
at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:261)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:964)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:956)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:956)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:775)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:738)
at sun.reflect.GeneratedMethodAccessor48.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:122)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:131)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy8.deploy(Unknown Source)
at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:305)
at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:481)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:204)
at org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:277)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:272)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:222)
at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:891)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:416)
at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:261)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:964)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:775)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:738)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:722)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:122)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:131)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
at $Proxy5.deploy(Unknown Source)
at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:413)
at org.jboss.system.server.ServerImpl.start(ServerImpl.java:310)
at org.jboss.Main.boot(Main.java:162)
at org.jboss.Main$1.run(Main.java:423)
at java.lang.Thread.run(Thread.java:534)


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 1:33 pm 
Expert
Expert

Joined: Tue Apr 25, 2006 12:04 pm
Posts: 260
Notice the comments within the mappings

Code:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

<hibernate-mapping default-cascade="none" default-access="property" auto-import="true">

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionTable" table="info_wf_action">

<composite-id>
   <key-property name="BatchId" column="batch_id" type="big_decimal"/>
   <key-property name="ActionId" column="action_id" type="big_decimal"/>
</composite-id>

<!-- What is the use of this many-to-one relation here, I commented it out as I dont see any use of it -->
<!-- <many-to-one name="BatchId" column="batch_id" not-null="true" update="false" insert="false"/> -->

<!-- following element is not needed in mapping -->
<!--<property name="ActionId" column="action_id" type="big_decimal" update="false" insert="true"/> -->

<property name="ActionTypeId" column="action_type_id" type="big_decimal" update="true" insert="true"/>
<property name="ActionTypeDesc" column="action_type_desc" type="string" update="true" insert="true"/>
<property name="Comments" column="comments" type="string" update="true" insert="true"/>

<property name="CreatedWho" column="cr_who" type="string" update="true" insert="true"/>
<property name="CreatedWhen" column="cr_when" type="timestamp" update="true" insert="true"/>
<property name="UpdatedWho" column="up_who" type="string" update="true" insert="true"/>
<property name="UpdatedWhen" column="up_when" type="timestamp" update="true" insert="true"/>

</class>

</hibernate-mapping>


Code:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

<hibernate-mapping default-cascade="none" default-access="property" auto-import="true">

<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaSignaturesTable" table="info_wf_action_signatures">

<composite-id>
   <key-property name="BatchId" column="batch_id" type="big_decimal"/>
   <key-property name="ActionId" column="action_id" type="big_decimal"/>
   <key-property name="SignatureId" column="signature_id" type="big_decimal"/>
   <key-property name="SignatureDate" column="signature_date" type="timestamp"/>
</composite-id>


<many-to-one name="ActionPk" not-null="true" update="false" insert="false" class="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionTable">
   <column name="batch_id"/>
   <column name="action_id"/>
</many-to-one>

<!-- again I commented out this one as I dont understand why this is here -->
<!-- <many-to-one name="SignatureId" column="signature_id" update="false" insert="true"/> -->

<!-- again I commented out this one as I dont understand why this is here -->
<!-- <property name="SignatureDate" column="signature_date" type="timestamp" update="false" insert="true"/> -->


<property name="Comments" column="comments" type="string" update="false" insert="true"/>
<property name="Email" column="email" type="string" update="false" insert="true"/>
<property name="EmplId" column="emplid" type="string" update="false" insert="true"/>
<property name="EmployeeNameFirst" column="emp_name_first" type="string" update="false" insert="true"/>
<property name="EmployeeNameLast" column="emp_name_last" type="string" update="false" insert="true"/>
<property name="ResultFlag" column="result_flag" type="string" update="false" insert="true"/>

</class>

</hibernate-mapping>


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 1:42 pm 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
Those m-2-1s are there because those fields are foreign keys to code tables and their values are supposed to be present in the other tables on insert.

Did as you suggested:

org.hibernate.MappingException: An association from the table info_wf_action refers to an unmapped class: java.math.BigDecimal


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 1:53 pm 
Expert
Expert

Joined: Tue Apr 25, 2006 12:04 pm
Posts: 260
I have no association defined in the mapping file for below class which is for table "info_wf_action"

Code:
<class name="us.tx.state.oag.WfPersonnelAction.hbm.HbmWfPaActionTable" table="info_wf_action">


and still the error is coming. Are you sure these mappings which you have edited are picking up.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 4:29 pm 
Beginner
Beginner

Joined: Tue Jul 25, 2006 12:34 pm
Posts: 25
As far as I know.

At this point, given the extreme difficulty of mapping tables, I think I'll just drop Hibernate. Or use it w/o relationships setup. Or organization prefers the use of Stored Procedures for most things anyway, which isn't properly supported anyway.

If there was a tool that could connect via JBDC to my database and build the mappings for me, then maybe I could grasp this things concepts but with error messages that are nonsensical, it just isn't worth my time.

I could have written something on my own already.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 02, 2006 5:27 pm 
Expert
Expert

Joined: Thu Dec 23, 2004 9:08 pm
Posts: 2008
Too much to read, too early in the morning. Is there still a question outstanding? Can you post it again? We can't have you dumping hibernate just because class vs. ID is confusing..

_________________
Code tags are your friend. Know them and use them.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 23 posts ]  Go to page 1, 2  Next

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.