Skip to main content
Participating Frequently
October 4, 2010
Question

Error while loading entity ORM

  • October 4, 2010
  • 2 replies
  • 2471 views

entityLoad('Account') throws this error,

Error while loading entity

java.sql.SQLException: [Macromedia][Oracle JDBC Driver]Numeric overflow.

However  entityLoad('Account',1) returns the proper record.

I am using oracle 10g as a datebase.

Is this a bug with oracle? entityLoad('Account') should return all my accounts.

    This topic has been closed for replies.

    2 replies

    Participating Frequently
    October 14, 2010

    Sorry for late reply , been away for a few days,

    I just added ormType=interger to my cfproprty that was the primary key and now all is good. I guess I should not assume an example that works fine for a diff database will work exactly the same on my database. I will make sure i define ormtype for every property.

    Inspiring
    June 3, 2021

    For some reason I am having the same error event though I checked the ormType="integer". My database is Oracle 19c and the primary key data type is "number". Thanks. 

    Community Expert
    June 3, 2021

    A number data type in Oracle is a float, not an integer. It's not the sort of thing you'd use as a surrogate key, but rather perhaps as a natural key. Anyway, you should be able to choose ormType="float" instead.

     

    Dave Watts, Eidolon LLC

    Dave Watts, Eidolon LLC
    Inspiring
    October 4, 2010

    How many records are we talking, and what's the definition of the entity?

    --

    Adam

    Participating Frequently
    October 4, 2010

    Just over 1000

    Now heres a kicker,  entityLoad('Account',{},'account_number asc',{offset=21, maxResults=10}) returns the proper 10 records

    but it still does not like it when i do

    entityLoad('Account')

    Inspiring
    October 5, 2010

    What if you use the offset & maxrows settings to return the whole lot? Does that work?

    If not, it might be bung data: try paging through all the records to see if one page in particular gives you a problem, then you can maybe narrow it down to a specific record.

    Can you profile the SQL that Hibernate is passing to the DB? Anything unexpected about it?

    --

    Adam