If that is the case, then why does
SELECT * FROM SourceDBF ;
WHERE ;
PRIN + Agent IN (SELECT PRIN + Agent FROM FAT_BASIC_AREAS_EXCLUSIONS) ;
and NOT DELETED() ;
INTO CURSOR curToRemove NOFILTER
SELECT * FROM SourceDBF ;
WHERE ;
PRIN + Agent IN (SELECT PRIN + Agent FROM FAT_BASIC_AREAS_EXCLUSIONS) ;
and NOT DELETED() ;
INTO CURSOR curToRemove NOFILTER
work when DELETED = OFF ,but just one of those statements does not work?
With DELETED = ON, then
SELECT * FROM SourceDBF ;
WHERE ;
PRIN + Agent IN (SELECT PRIN + Agent FROM FAT_BASIC_AREAS_EXCLUSIONS) ;
and NOT DELETED() ;
INTO CURSOR curToRemove NOFILTER
works just fine. Note the AND NOT DELETED() is still in the query.
I looked at your reference and I fully understand it. I have known about that for a very long time and use table references with care. In this case, there is no table reference.
In fact, only one other time (that I can remember) have I ever run into this problem where the first time a line is run it does not give the desired results. I don't remember what it was that I was doing, but I believe that DELETED = OFF was the case there as well. I don't know if NOT DELETED() was in the SQL or not at that time.
David
David