logical-reads

Large number of "logical reads" on single row delete

Hi, When deleting a row by its PrimaryKey from a table, I get about 44472 logical reads. Now the table has 5-6 child tables that link their ForeignKeys to the PK of the table I want to delete from. I'm not sure what to do to improve the performance of the delete. Any suggestions ? Edit : I added the queryplan for the delete http://...

Unit testing Sql for logical reads

We have unit tests for our data access layer. This has helped to spot sql syntax errors. Now that we have these tests I would like to take it one step further. I would like to run the unit tests and find sql that has a high number of logical reads, Automatically.(to find sql in need of tuning) Adding "set statistics IO" to the sql is no...