>I have a cursor open with table buffering to which records get appended. At one point in my form I would like to "resort" all the records in order to perform some checks before the records get saved. So, what I would like to do is a SELECT * FROM ALIAS() ORDER BY fields
>Therefore re-sorting all the records that are in the uncommited table in memory. However, this SELECT statement gets the fields from the commited records in the table, not the current uncommited table in memory. What can I do?
SQL Selects open the target table again in another workarea in order to optimize themselves. Because of this, they have to work with the disk version of the table.
You need use commands that work with the memory version. SCAN/ENDSCAN, DO WHILE/SKIP/ENDDO. Basically you need to copy your table to another source so you can work with it.
Because of the overhead in this, I would not recommend it. I would suggest that you post your reasons for wanting to do this. You state you want to perform some checks on the modified records before updating them. I'm confused as to why you would need to do this. Can't the checks be made on an unsorted table? If not, then why? Maybe there is another way to reach your goal.
Just some ideas.
Larry Miller
MCSD
LWMiller3@verizon.netAccumulate learning by study, understand what you learn by questioning. -- Mingjiao