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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T14:29:27+00:00 2026-05-27T14:29:27+00:00

I’m using hibernate tools to automatically create a class that represents a table in

  • 0

I’m using hibernate tools to automatically create a class that represents a table in an Oracle database, the table has a large number of columns (60 or more) I’ve mapped what I think the hibernate type should be, I’ve obviously mapped something wrong as I get the following when trying to query the table

Caused by: java.sql.SQLException: Fail to convert to internal
representation at
oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:111)
at
oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:145)
at
oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:207)
at
oracle.jdbc.driver.CharCommonAccessor.getLong(CharCommonAccessor.java:238)
at
oracle.jdbc.driver.OracleResultSetImpl.getLong(OracleResultSetImpl.java:557)
at
oracle.jdbc.driver.OracleResultSet.getLong(OracleResultSet.java:1574)
at
org.hibernate.type.descriptor.sql.BigIntTypeDescriptor$2.doExtract(BigIntTypeDescriptor.java:61)
at
org.hibernate.type.descriptor.sql.BasicExtractor.extract(BasicExtractor.java:64)
at
org.hibernate.type.AbstractStandardBasicType.nullSafeGet(AbstractStandardBasicType.java:254)
at
org.hibernate.type.AbstractStandardBasicType.nullSafeGet(AbstractStandardBasicType.java:250)
at
org.hibernate.type.AbstractStandardBasicType.nullSafeGet(AbstractStandardBasicType.java:230)
at
org.hibernate.type.AbstractStandardBasicType.hydrate(AbstractStandardBasicType.java:331)
at
org.hibernate.persister.entity.AbstractEntityPersister.hydrate(AbstractEntityPersister.java:2283)
at org.hibernate.loader.Loader.loadFromResultSet(Loader.java:1527)
at org.hibernate.loader.Loader.instanceNotYetLoaded(Loader.java:1455)
at org.hibernate.loader.Loader.getRow(Loader.java:1355) at
org.hibernate.loader.Loader.getRowFromResultSet(Loader.java:611) at
org.hibernate.loader.Loader.doQuery(Loader.java:829) at
org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:274)
at org.hibernate.loader.Loader.doList(Loader.java:2542) … 9 more

Obviously with there being over 60 columns it’s not easy to track down which column(s) I’ve mapped incorrectly, so I’m looking for a bit of advice of what type to map to. At the moment I’ve made the following assumptions

NUMBER(Max length of 12 min length of 2) -> long
VARCHAR2(Max length of 1000 min length of 1) -> string
DATE -> timestamp

Edit: To clarify the above I have number columns ranging in size from NUMBER(2) – NUMBER(12). And VARCHAR2 columns ranging from VARCHAR2(1) – VARCHAR2(1000)

  • 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-27T14:29:28+00:00Added an answer on May 27, 2026 at 2:29 pm

    Ok sorted it wasn’t mapping the types that was the problem I was mapping a column to a long when it should have been a string.

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

Sidebar

Related Questions

That's pretty much it. I'm using Nokogiri to scrape a web page what has
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I've got a string that has curly quotes in it. I'd like to replace
I'm trying to create an if statement in PHP that prevents a single post
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I want to count how many characters a certain string has in PHP, but
I am reading a book about Javascript and jQuery and using one of the
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and

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.