Im grateful for some assistance for a bug in my application that is puzzling me !!
I check the number of rows in a table that contain the PersonID of the person i am looking up using:
cmd.commandtext = "SELECT Count (*) from PeopleDetails where PersonID = '11111'"
count = cmd.executescalar()
This works 98% of the time. Occasionally the count variable has data from the first column of the row being queried which is a GUID in the table called rowid. It does not have the expected integer of the number of rows that met the condition. The connection is live and if the query is repeated it returns the correct count value.
This is seen most when the server is busiest first thing in the morning when there are multiple simultaenous queries to the the database.
Help most welcome !!
SQL server 2003, vb.net
Thanks for looking !