its not from the address, but from the company. the compny can have a crmStatus.
Hibernate: select this.company_id as company_id3_, this.company_name as company_2_3_, this.phone as phone3_, this.phone2 as phone23_, this.fax as fax3_, this.url as url3_, this.employees as employees3_, this.profile as profile3_, this.remark as remark3_, this.default_primary_address as default10_3_, this.entered_at as entered_at3_, this.entered_by as entered_by3_, this.last_modified_at as last_mo13_3_, this.last_modified_by as last_mo14_3_, this.crm_status_id as crm_sta15_3_, this.industry_id as industr16_3_, this.user_id as user_id3_, crmstatus1_.crm_status_id as crm_stat1_0_, crmstatus1_.crm_status_short_name as crm_stat2_0_, crmstatus1_.crm_status_pretty_name as crm_stat3_0_, industry2_.industry_id as industry1_1_, industry2_.industry_short_name as industry2_1_, industry2_.industry_pretty_name as industry3_1_, user3_.user_id as user_id2_, user3_.username as username2_, user3_.password as password2_ from companies this left outer join crm_statuses crmstatus1_ on this.crm_status_id=crmstatus1_.crm_status_id left outer join industries industry2_ on this.industry_id=industry2_.industry_id left outer join users user3_ on this.user_id=user3_.user_id where this.company_id=?
Hibernate: select crmstatus0_.crm_status_id as crm_stat1_0_, crmstatus0_.crm_status_short_name as crm_stat2_0_, crmstatus0_.crm_status_pretty_name as crm_stat3_0_ from crm_statuses crmstatus0_ where crmstatus0_.crm_status_id=?
ERROR [http-8080-Processor25] (CompanyDAO.java:112) - Hibernate Exception
net.sf.hibernate.UnresolvableObjectException: No row with the given identifier exists: 0, of class: de.woco.moslokal.businessobject.CrmStatus
at net.sf.hibernate.UnresolvableObjectException.throwIfNull(UnresolvableObjectException.java:38)
at net.sf.hibernate.impl.SessionImpl.internalLoad(SessionImpl.java:1964)
at net.sf.hibernate.type.ManyToOneType.resolveIdentifier(ManyToOneType.java:69)
at net.sf.hibernate.type.EntityType.resolveIdentifier(EntityType.java:208)
at net.sf.hibernate.impl.SessionImpl.initializeEntity(SessionImpl.java:2219)
at net.sf.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:319)
at net.sf.hibernate.loader.Loader.doQuery(Loader.java:309)
at net.sf.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:138)
at net.sf.hibernate.loader.Loader.doList(Loader.java:1063)
at net.sf.hibernate.loader.Loader.list(Loader.java:1054)
at net.sf.hibernate.loader.CriteriaLoader.list(CriteriaLoader.java:118)
at net.sf.hibernate.impl.SessionImpl.find(SessionImpl.java:3660)
at net.sf.hibernate.impl.CriteriaImpl.list(CriteriaImpl.java:238)
at net.sf.hibernate.impl.CriteriaImpl.uniqueResult(CriteriaImpl.java:385)
at de.woco.moslokal.persistencelayer.CompanyDAO.getCompanyByOid(CompanyDAO.java:96)
at de.woco.moslokal.service.BusinessDelegate.getCompanyByOid(BusinessDelegate.java:140)
at de.woco.moslokal.action.CompanyAction.getCompanyByOid(CompanyAction.java:433)
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:585)
at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.java:276)
at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:196)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:421)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:226)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1164)
at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:397)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
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.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:731)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
[WARN] SessionImpl - afterTransactionCompletion() was never called
|