I have a MS SQL 2008 database which has a number of tables.
I have two applications. One writes to a couple of tables. The other reads these tables.
The applications run as windows services.
I have discovered that the reader application can read data from the database whilst the writer is still writing it ( there is more than one row of data written in one table. The read sometimes does not get all the rows).
How can i "protect" the written data until it has been written completly? Can i use a combination of transacations and setting the isolation level to the correct value?