These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Column 'Code' not found.
PostPosted: Mon Oct 31, 2005 7:44 pm 
Newbie

Joined: Mon Oct 31, 2005 7:04 pm
Posts: 2
I'm making a normal HQL call that asked is to return a list of major themes and using many-to-many relationships, each has a list of themes that are under it.

Many of the SQL called work fine, but some; and not consistently the same one come back with the following weird error.

Oct 31, 2005 6:36:27 PM org.hibernate.util.JDBCExceptionReporter logExceptions
WARNING: SQL Error: 0, SQLState: S0022
Oct 31, 2005 6:36:27 PM org.hibernate.util.JDBCExceptionReporter logExceptions
SEVERE: Column 'Code' not found.

Query being executed when exception was thrown:

select themes0_.MajorThemeId as MajorThe1_1_, themes0_.ThemeId as ThemeId1_, theme1_.ThemeId as ThemeId0_, theme1_.ThemeDescription as ThemeDes2_6_0_ from bts_themes_crossref themes0_ inner join bts_themes theme1_ on themes0_.ThemeId=theme1_.ThemeId where themes0_.MajorThemeId=5

What I am trying to understand is why hibernate thinks that is mythical "Code" column should exist? It's certainly not part of my mapping file or table, never has been.

Anyone really familiar with the code of hibernate have any idea, or possible work-around, better yet a bug-fix.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Oct 31, 2005 10:00 pm 
Beginner
Beginner

Joined: Thu Jan 22, 2004 8:22 pm
Posts: 48
My experience has been that this exception indicates the database JDBC driver has thrown a exception which Hibernate does not recognize/expect. You'll need to look at your database documentation for possible cause of SQLState S0022.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.