How to debug NHibernate mapping?

I am using NHibernate (2.0.1GA) with my project. At runtime, I get

Invalid Cast (check your mapping for property type mismatches); 
[...]

So, he only says that he can’t give up something. This is a little fuzzy imho.

My mapping file is quite large (main table with approximately 50 columns plus 11 subsets). How to find an invalid listing without checking each row in it for the corresponding classes and tables ?!

+3
source share
2 answers

Hold pdbs (or just get the source code), and figure out where the exception is thrown first, and then go back on the stack until you see what it is trying to do.

+1
source

, ? , :-): ...

, , . ...


, , NHibernate , , .

0

Source: https://habr.com/ru/post/1719876/


All Articles