Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6745163
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T12:10:17+00:00 2026-05-26T12:10:17+00:00

I know that this is a common question that was described a lot of

  • 0

I know that this is a common question that was described a lot of times.
But still I can’t get some thing – what about performance? Which method is faster?

Actually, I need a simple thing: the page makes a POST-request: id=0, name=’John’. The server-side script should check if id=0, then create a new record in DB, otherwise update existing.

I think that get() is more usefull for me because it will return a NULL in case of record is not exists in DB, while load() can return some temproray object.. Am I right?
Thank you

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T12:10:18+00:00Added an answer on May 26, 2026 at 12:10 pm

    Here’s a link to the equivalent question in the Hibernate forum which was the first result in my google query (Hibernate load vs get): https://forum.hibernate.org/viewtopic.php?p=2387456

    There it states the following:

    The load() method is older; get() was added to Hibernate’s API due to user
    request. The difference is trivial:

    If load() can’t find the object in the cache or database, an exception is
    thrown. The load() method never returns null. The get() method returns
    null if the object can’t be found.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know this is a common question but I just can't seem to get
I know that this may be an amateur question but for some reason I
I know that this question is quite common, but its specifics are stumping me.
I know that this question is asked a lot, I checked all of the
I know that this question has been asked several times and I've read all
I know this has probably been answered as it seems a common question but
Okay, I know this is a common enough question, but all the solutions I've
I know this a common question but everything I found seems to remove white
HI, I know this is a very common question in case of .Net, but
I know this question is very common but the main point in my question

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.