• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Error : No row with the given identifier exists

 
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi I am getting the following exception in hibernate when I am loading the application in the test server. However I am not getting any exception in my development server. Can you please update if you know the solution or the root cause.


com.xyz.sspglobal.admin.dao.AdminDaoException: No row with the given identifier exists: 307, of class: com.xyz.sspglobal.admin.models.BusinessInfo; nested exception is net.sf.hibernate.UnresolvableObjectException: No row with the given identifier exists: 307, of class: com.xyz.sspglobal.admin.models.BusinessInfo: org.springframework.orm.hibernate.HibernateObjectRetrievalFailureException: No row with the given identifier exists: 307, of class: com.xyz.sspglobal.admin.models.BusinessInfo; nested exception is net.sf.hibernate.UnresolvableObjectException: No row with the given identifier exists: 307, of class: com.xyz.sspglobal.admin.models.BusinessInfo
at com.xyz.sspglobal.admin.dao.HbBusinessDao.loadSB(HbBusinessDao.java:25)
at com.xyz.sspglobal.admin.AdminBusinessManagerImpl.reload(AdminBusinessManagerImpl.java:49)
at com.xyz.sspglobal.admin.AdminBusinessManagerImpl.init(AdminBusinessManagerImpl.java:40)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java(Compiled Code))
at java.lang.reflect.Method.invoke(Method.java(Compiled Code))
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:996)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:966)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:354)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:223)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:277)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:312)
at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:82)
at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:67)
at com.xyz.reuse.spring.util.BeanRetrieveUtil.retrieveContext(BeanRetrieveUtil.java:40)
at com.xyz.reuse.spring.SpringSupportManager.init(SpringSupportManager.java:42)
at com.xyz.reuse.framework.AppModuleLoader.initModule(AppModuleLoader.java:69)
at com.xyz.reuse.framework.AppModuleLoader.init(AppModuleLoader.java:49)
at com.xyz.reuse.framework.WebApp2.loadAppModules(WebApp2.java:110)
at com.xyz.reuse.framework.WebApp2.init(WebApp2.java:68)
at com.xyz.reuse.framework.WebServlet$WebAppInitializer.run(WebServlet.java:102)
at java.lang.Thread.run(Thread.java:568)

[ July 03, 2007: Message edited by: Yousuff Mohammed ]
 
Bartender
Posts: 10336
Hibernate Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

No row with the given identifier exists: 307, of class: com.xyz.sspglobal.admin.models.BusinessInfo;


Looks like you are trying to populate an object called BusinessInfo with the ID of 307 that doesn't exist in the database.
 
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am also getting same exception that is seems to be happening because of ehcache.

The id which it is showing was changed object and updated,
it does not exists no more in data base. But it trying to load those objects (i think those objects are may be resided in cache).


 
Charan kumar sarvepalli
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
not-found = "ignore" is added to <one-to-many> element to avoid the exception then works fine.
 
Ranch Hand
Posts: 241
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Charan kumar sarvepalli wrote:not-found = "ignore" is added to <one-to-many> element to avoid the exception then works fine.



I am having same exception but not-found = "ignore" does not compile.
Anyone can explain this exception?
 
reply
    Bookmark Topic Watch Topic
  • New Topic