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.
|