Does anyone know if SqlClient.DataReader locks the rows that is it currently reading?
I have a recursive call that that tries to execute "update" commands on the current row but it times out. (These are simle commands like "update table set field = value where primatykeyfield = 2". Nothing fancy, - in fact they run fine in the query analyser, but not at runtime.) I can't close the reader because I have more rows to process (to "read". I need to use the "update" sql to mark the current row as being processed so it won't be processed the next time this feature is executed.
My theory is that the ADO.Net Reader locks the "read" rows. Does this sound possible? If so, can the behavior be changed?
I have a recursive call that that tries to execute "update" commands on the current row but it times out. (These are simle commands like "update table set field = value where primatykeyfield = 2". Nothing fancy, - in fact they run fine in the query analyser, but not at runtime.) I can't close the reader because I have more rows to process (to "read". I need to use the "update" sql to mark the current row as being processed so it won't be processed the next time this feature is executed.
My theory is that the ADO.Net Reader locks the "read" rows. Does this sound possible? If so, can the behavior be changed?