From: Max R. A. (JIRA) <no...@at...> - 2006-06-09 07:11:34
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1825?pa= ge=3Dcomments#action_23303 ]=20 Max Rydahl Andersen commented on HHH-1825: ------------------------------------------ add a patch and it will be done faster > Improved mesage in Exception from Table.validateColumns > ------------------------------------------------------- > > Key: HHH-1825 > URL: http://opensource.atlassian.com/projects/hibernate/browse/H= HH-1825 > Project: Hibernate3 > Type: Improvement > Components: metamodel > Versions: 3.1.2 > Reporter: Bj=C3=B8rn Bjerkeli > Priority: Minor > > > The method validateColumns in Table throws an exception when it encounter= s a missing column. Each time I encounter this problem, I have to start the= debugger and create a breakpoint to identify the which table that has the = missing column. > So instead of: > if ( columnInfo =3D=3D null ) { > =09=09=09=09throw new HibernateException( "Missing column: " + col.getNam= e() ); > } > Add proper context to the Exception: > if ( columnInfo =3D=3D null ) { > =09=09=09=09throw new HibernateException( "Table:"+this+has " missing col= umn: " + col.getName() ); > } > This will make it trivial to identify and correct the bogus mapping or sc= hema. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators= .jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |