exception handling - Why is NHibernate swallowing a SQL error from a lazy-loaded collection? -
i've got entity maps collection of components follows:
<class name="teacherresource" table="teacherresource"> <id name="teacherresourceid"> <generator class="guid"/> </id> <!-- irrelevant properties here... --> <bag name="helpfullinks" order-by="boguscolumnname"> <key column="teacherresourceid"/> <composite-element class="helpfullink"> <property name="href"/> <property name="display"/> </composite-element> </bag> </class> at first wasn't getting data collection, realized had incorrect column name in there ordering collection. nhibernate doesn't throw exception, if view property in debugger after property lazy-loaded, there innerexception defined indicates error.
why nhibernate trap error? i'm on .net 4.0/nh 3.3.1.

as said, nhibernate never swallows exceptions. collection loaded data binding, in case data binding swallowed exception.
Comments
Post a Comment