[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: %%%% Error Creating SessionFactory %%%%
waq
do-not-reply at jboss.com
Fri May 29 08:03:49 EDT 2009
yes that was the mistake i did. NOw i changed the ID type to Number(oracle number). When i did the reverse engineering it made the ID of BigDecimal type. Now when i try to insert a record it gives me exception:
| SEVERE: org.hibernate.id.IdentifierGenerationException: this id generator generates long, integer, short
| javax.faces.el.EvaluationException: org.hibernate.id.IdentifierGenerationException: this id generator generates long, integer, short
| at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:102)
| at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
| at javax.faces.component.UICommand.broadcast(UICommand.java:387)
| at javax.faces.component.UIData.broadcast(UIData.java:938)
| at org.ajax4jsf.component.AjaxViewRoot.processEvents(AjaxViewRoot.java:321)
| at org.ajax4jsf.component.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:296)
| at org.ajax4jsf.component.AjaxViewRoot.processPhase(AjaxViewRoot.java:253)
| at org.ajax4jsf.component.AjaxViewRoot.processApplication(AjaxViewRoot.java:466)
| at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
| at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
| at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
| at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:178)
| at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
| at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:390)
| at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:517)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
| at java.lang.Thread.run(Unknown Source)
| Caused by: org.hibernate.id.IdentifierGenerationException: this id generator generates long, integer, short
| at org.hibernate.id.IdentifierGeneratorFactory.createNumber(IdentifierGeneratorFactory.java:119)
| at org.hibernate.id.IncrementGenerator.generate(IncrementGenerator.java:47)
| at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:85)
| 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:481)
| at org.hibernate.impl.SessionImpl.save(SessionImpl.java:476)
| at table.detail.DetailDAO.save(DetailDAO.java:32)
| at ecs.admin.InsertSuggestion.insert(InsertSuggestion.java:121)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
| at java.lang.reflect.Method.invoke(Unknown Source)
| at org.apache.el.parser.AstValue.invoke(AstValue.java:152)
| at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
| at org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:68)
| at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
| ... 29 more
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4234104#4234104
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4234104
More information about the jboss-user
mailing list