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

  • Home
  • SEARCH
  • 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 8323685
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T23:47:46+00:00 2026-06-08T23:47:46+00:00

I have a requirement wherein I need to support both Oracle and PostgreSQL. I

  • 0

I have a requirement wherein I need to support both Oracle and PostgreSQL. I have following hibernate mapping –

<id name="id" type="java.lang.Integer">
    <column name="id"  not-null="true" />
    <generator class="native">
        <param name="sequence">`OneTimeAccessToken_id_seq`</param>
    </generator>
</id>
<property name="resource" type="java.lang.String">
    <column name="`res`" not-null="true" />
</property>
<property name="expires" type="long">
    <column name="`expires`" not-null="true" />
</property>

However this does not work for Oracle, since it has that backquote. If I remove the backquote, it fails for PostgreSQL. Any inputs on how to provide support for both databases.

I am using org.hibernate.dialect.Oracle10gDialect against Oracle 11.2 version, it that right?

My problem are the backticks and not making sequence compatible across databases. I have already achieved that. I used backticks in the hbm files to make PostgreSQL create table/columns as per the character case I specified. If I remove those backticks, PostgreSQL translates everything to lowercase. Now with backticks in place, everything works fine with PostgreSQL, however, it creates issues with Oracle saying it cannot find table or view: “OneTimeAccessToken”. I am trying to identify how I should solve this problem of maintaining table/column name cases and also make it work against Oracle.

  • 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-06-08T23:47:47+00:00Added an answer on June 8, 2026 at 11:47 pm

    there is a specialised generator for this

    <generator class="sequence-identity">
        <param name="sequence">OneTimeAccessToken_id_seq</param>
    </generator>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a requirement wherein I need to display on a User form, a
I am new to extension development, I have a requirement wherein I need to
I have a requirement in JasperReports wherein I need to display the field based
I have a requirement wherein i should write a method of type String[] and
I have a requirement wherein I need to display a list of employees and
I have a requirement, wherein i need to show a wait message while an
I have a requirement wherein I need to launch an application (assumed to be
I have requirement, wherein I have to calculate totals for cash and credit cards
I have requirement as following like showing ABPeoplePickerNavigationController in tabbar based application. I researched
Hi i have requirement to process large number of files via multithreading in java.

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.