>>I got a slight surprise to see the record pointer being moved while using the SQL Update command.
>>I would have thought, that like other SQL commands, noteably SQL Select, that the record pointer wouldn't be moved.
>>I wouldn't say this was a "bug" but it would be nice to see the pointer restored automatically after the operation.
>
>Are you referring to a table open in the current select area whose pointer gets moved if a SQL is executed against other tables? I would be interested in such details.
>
>Thanks.
It was a simple
UPDATE Ops ;
SET Extno = SPACE(4), ;
LoggedOn = .F. ;
WHERE Extno = app.extno
I don't really care if it's the currently selected table or not. This moves the record pointer for "Ops" to EOF(). My view is that it should not move at all. Otherwise I'd simply use the old SCAN technique
SCAN FOR Extno = app.extno
REPLACE Extno WITH SPACE(4), LoggedOn WITH .F.
ENDSCAN