I am debugging old application and can't understand the existing behaviour.
A form with private datasession and at some stage in debugger
I can see in watch window - record is not deleted ( deleted() .F. ) , seq = 1234 ( primary key ) , set deleted on , mytable is current alias
However
select count(*) from mytable where seq=1234 into array lacount
results in lacount[1] = 0
select count(*) from mytable where seq=1234
Empty query
But
Locate for seq=1234
results in found() - .T.
We may suspect that something wrong with the index ( primary key ) , but once form is closed , sql works fine. Is it something to do with buffering and flushing which I am not aware of ?