What is use of having SQLWarnings?
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Sandeep_Shilawat
Posted On:   Tuesday, October 14, 2003 12:03 PM

What is use of having SQLWarnings? In Sybase 12.5 when I try to insert NaN, it does not raise any exception but my executeUpdate returns with 0 rows inserted. That means no exceptions raised when I fetch the warning then I get "3622: 10: Domain error occurred." with 3622 as Error code. My understanings was SQLWarning is an SQLException which is not thrown as it is not necessary to terminate the process. I am a bit confused about use of SQLWarnings. For me insertion failure is a fatal error. But here Vendor can get away with a fact that he raised the SQLWarning, which inturn leaves my code unportable to the next db version. WHY DO WE HAVE THIS SQLWarnings class? It just leaving lot of grey ar   More>>

What is use of having SQLWarnings?


In Sybase 12.5 when I try to insert NaN, it does not raise any exception but my executeUpdate returns with 0 rows inserted. That means no exceptions raised when I fetch the warning then I get "3622: 10: Domain error occurred." with 3622 as Error code.


My understanings was SQLWarning is an SQLException which is not thrown as it is not necessary to terminate the process. I am a bit confused about use of SQLWarnings. For me insertion failure is a fatal error. But here Vendor can get away with a fact that he raised the SQLWarning, which inturn leaves my code unportable to the next db version.


WHY DO WE HAVE THIS SQLWarnings class? It just leaving lot of grey area for me. Any thoughts !!!

   <<Less
About | Sitemap | Contact