• 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

How to stop exection of query for many to one

 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am trying to stop some unwanted sql query execution due relation in .hbm.xml

By using lazy="proxy" the sql query for that class not executed but if I used both 'not-found="ignore" lazy="proxy"' then it can not stop the execution of query

My entry in .hbm.xml is like

<many-to-one name="state" class="com.ind.model.CodeValue" not-found="ignore" lazy="proxy">
<column name="State" not-null="false" />

the select query also executes for CodeValue
</many-to-one>
due to which for every require select query , query for code value also executed resulting a performance hit.

Thanks & Regards,
Raj
[ March 18, 2008: Message edited by: Rajan Nath ]
 
reply
    Bookmark Topic Watch Topic
  • New Topic