Quote:
Originally Posted by murg
Exception handling (Try/Catch) came out of academia. Basically, a bunch on non-practicing programmers decided that returning errors was wrong, and decided to force us to use, as you so aptly termed it, a controlled crash. And, of course, unless you have try/catch blocks around every statement, you're never quite sure what triggered the exception.
Joel is a practising programmer, so he knows how stupid the whole try/catch thing is.
The really stupid thing is that Microsoft is moving the error handing in SQL Server into a try/catch model; check out the reduced functionality of THROW as opposed the RAISERROR. I'm sorry, but does Microsoft think we are too stupid to set our own Severity (which is probably mostly used to force the PRINT and RAISERROR messages to flush to the SSMS (or is it SSMC?) session.
|
This. I know a very bright guy with a C.S. degree (and a masters) who thinks that the best error handling is to have the code stack dump and let the user email the stack dump in to tech support. He's what I call a white paper programmer, i.e. programs with an eye to architectural purity rather than robustness or maintainability. That's what happens when you have a friction-less surface mindset. I'm firmly in the K.I.S.S. camp.