Some quick and easy performance tips for ADO.NET, courtesy of Adam Machanic.
He talks about calling GetOrdinal before looping through a DataReader. We do the same thing with classic ADO in Delphi when we need to optimize the scrolling through a recordset.
The other tip is to use static cases instead of Get
Roman Rehak commented with the tip to always close the explicitly connection when you are done with the reader.
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.