Summary


One of the most important aspects of executing any T-SQL against SQL Server is being prepared for the results. Sure, this means capturing the rowsets that return as well as the OUTPUT and RETURN parameter values, but it also means trapping the exceptions. The topics I visited in this chapter should give you a better understanding of how to execute a SqlCommand either synchronously or asynchronously and deal with the resultswhether or not the query did what was intended. Using these techniques, you can pull down rowsets and manage complex resultsets and deal with the events and exceptions these operations can invoke. I also talked about how to manage the low-level data stream as well as how to process the rowsets and returned parameters. Since stored procedures and the OUTPUT parameters are an integral part of many designs, I'm sure you'll find these techniques useful. Just be prepared for the stuff that happens when you execute any T-SQLyou never know when SQL Server will get fussy and talk back.




Hitchhiker's Guide to Visual Studio and SQL Server(c) Best Practice Architectures and Examples
Hitchhikers Guide to Visual Studio and SQL Server: Best Practice Architectures and Examples, 7th Edition (Microsoft Windows Server System Series)
ISBN: 0321243625
EAN: 2147483647
Year: 2006
Pages: 227

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net