Win a copy of Micro Frontends in Action this week in the Server-Side JavaScript and NodeJS forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Biggest Hibernate mistake?

 
Ranch Hand
Posts: 479
2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What do you see as the biggest mistake people make when using Hibernate ?
 
author
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would have to say proper utilization of hibernate (may be not a mistake). I think the association mappings are done all the time, but when it comes to inheritance mapping, it is not fully used. So is fetching complete entities all the time when only certain scalar values are required. Of course this is from my experience.

Regards

Srinivas
 
paul nisset
Ranch Hand
Posts: 479
2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you.
 
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

So is fetching complete entities all the time when only certain scalar values are required.



Being a novice with Hibernate, what do you do to address this?
Do you create abridged classes that contain only your pertinent values?

-Fred
 
Ranch Hand
Posts: 527
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Fred Muhlenberg wrote:

So is fetching complete entities all the time when only certain scalar values are required.



Being a novice with Hibernate, what do you do to address this?
Do you create abridged classes that contain only your pertinent values?

-Fred



We can acheive this by using SQL query to get a list of scalars instead of generic "select * from"

More on this topic is here.
 
Fred Muhlenberg
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
An interesting technique. I never knew.

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the tip, this is a cool topic~
 
Bring out your dead! Or a tiny ad:
the value of filler advertising in 2020
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic