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 3804554
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T14:32:12+00:00 2026-05-19T14:32:12+00:00

We are encountering strange hibernate behavior with hbm2ddl.auto set to update . In our

  • 0

We are encountering strange hibernate behavior with hbm2ddl.auto set to update.

In our test setup, we have two database users, one containing the tables for our beta application, the other one is mainly used for development. I.e. same table names with different users.
When new tables are to be created, we do so by using hbm2ddl.auto=update.

Now suddenly the strange behavior is: the update process looks for existing tables with the wrong user and creates those not found with the right user.

E.g. if the following tables exists

USER_A.TABLE_1
USER_B.TABLE_2

and we update with three tables configured: TABLE_1, TABLE_2, TABLE_3 using USER_B, we end up with

USER_A.TABLE_1
USER_B.TABLE_2
USER_B.TABLE_3

TABLE_1 is not created for USER_B. After renaming USER_A.TABLE_1 to USER_A.TABLE_0 and updating again we end up with the expected result:

USER_A.TABLE_0
USER_B.TABLE_1
USER_B.TABLE_2
USER_B.TABLE_3

Does this make any sense to anyone? Is there something like an internal hibernate cache remembering like “Hey I have already created this table on this server (and I do not care about the user)”.

We have spent quite some testing to reassure this is not a configuration problem, reproduced this on different machines, different configurations, from ant or using the IDE, making sure USER_A’s password cannot be found anywhere in the build directory etc. So we are 100% sure, the behavior is as described – but we are completely out of ideas what happens.

I’d be very happy to hear your ideas about this, since this problem is nagging for some time now.

Thanks a lot,
Peter

  • 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-19T14:32:13+00:00Added an answer on May 19, 2026 at 2:32 pm

    Is there something like an internal hibernate cache remembering like “Hey I have already created this table on this server (and I do not care about the user)”.

    No. What is probably happening is that USER_A can see the tables created under USER_B account, and vice-versa. It’s not clear which database you are using, but I would try to configure Hibernate to use two different schemas, in addition to use just different users. You may also want to try to set the property “hibernate.default_schema”, but I’m not sure that this only will solve your problem.

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

Sidebar

Related Questions

So I am seemingly encountering some strange behavior when using NSString 's -sizeWithFont family
I am using core data with preloaded sqlite database. I am encountering a strange
I've been encountering some strange behavior when trying to find a key inside a
I am encountering a strange problem when trying to create two dropdowns where the
I'm encountering a very strange problem using g++ 4.1.2. I have a very basic
Unexpected behavior: I am encountering strange behavior of Oracle sequences with 11g (works with
I'm encountering a very strange error. I have an app ID defined in my
I'm encountering a very strange issue while debugging a unit test. If I debug
I am encountering strange behavior on my gnuplot script. The objective of this script
I am encountering some strange behavior with using the matplotlib.pyplot ginput() function to store

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.