[Java]
Java. lang. ClassCastException: java. math. BigInteger cannot be cast to java. lang. Long
At badyflf. action. impl. HibernateProductDao. findByPnum (HibernateProductDao. java: 79)
At badyflf. test. TestMain. findByPnum (TestMain. java: 37)
At sun. reflect. NativeMethodAccessorImpl. invoke0 (Native Method)
At sun. reflect. NativeMethodAccessorImpl. invoke (NativeMethodAccessorImpl. java: 39)
At sun. reflect. DelegatingMethodAccessorImpl. invoke (DelegatingMethodAccessorImpl. java: 25)
At java. lang. reflect. Method. invoke (Method. java: 597)
At org. junit. runners. model. FrameworkMethod $1. runReflectiveCall (FrameworkMethod. java: 44)
At org. junit. internal. runners. model. ReflectiveCallable. run (ReflectiveCallable. java: 15)
At org. junit. runners. model. FrameworkMethod. invokeExplosively (FrameworkMethod. java: 41)
At org. junit. internal. runners. statements. InvokeMethod. evaluate (InvokeMethod. java: 20)
At org. junit. internal. runners. statements. RunBefores. evaluate (RunBefores. java: 28)
At org. junit. internal. runners. statements. RunAfters. evaluate (RunAfters. java: 31)
At org. junit. runners. BlockJUnit4ClassRunner. runChild (BlockJUnit4ClassRunner. java: 73)
At org. junit. runners. BlockJUnit4ClassRunner. runChild (BlockJUnit4ClassRunner. java: 46)
At org. junit. runners. ParentRunner. runChildren (ParentRunner. java: 180)
At org. junit. runners. ParentRunner. access $000 (ParentRunner. java: 41)
At org. junit. runners. ParentRunner $1. evaluate (ParentRunner. java: 173)
At org. junit. internal. runners. statements. RunBefores. evaluate (RunBefores. java: 28)
At org. junit. internal. runners. statements. RunAfters. evaluate (RunAfters. java: 31)
At org. junit. runners. ParentRunner. run (ParentRunner. java: 220)
At org. eclipse. jdt. internal. junit4.runner. JUnit4TestReference. run (JUnit4TestReference. java: 46)
At org. eclipse. jdt. internal. junit. runner. TestExecution. run (TestExecution. java: 38)
At org. eclipse. jdt. internal. junit. runner. RemoteTestRunner. runTests (RemoteTestRunner. java: 467)
At org. eclipse. jdt. internal. junit. runner. RemoteTestRunner. runTests (RemoteTestRunner. java: 683)
At org. eclipse. jdt. internal. junit. runner. RemoteTestRunner. run (RemoteTestRunner. java: 390)
At org. eclipse. jdt. internal. junit. runner. RemoteTestRunner. main (RemoteTestRunner. java: 197)
Solution:
Set
<Property name = "addTime" type = "long">
<Columnname = "add_time"/>
</Property>
To:
<Property name = "addTime" type = "java. math. BigInteger">
<Columnname = "add_time"/>
</Property>