Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Dupe records? What's up with SCAN FOR command?
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00692395
Message ID:
00692401
Views:
12
This message has been marked as a message which has helped to the initial question of the thread.
I think you can do it with a query.
SELECT ;
		mast_id, ;
		incident AS run_num, ;
		date AS run_date, ;
		name_last, ;
		name_first, ;
		phone ;
	FROM master ;
	WHERE NOT EMPTY(msca_close) ;
		AND NOT EMPTY(msca_id) ;
		AND NOT EMPTY(disto)  ;
		AND date < (DATE() - 30) ;
		AND mast_id NOT IN ( ;
			SELECT mast_id FROM surv_sca) ;
	INTO CURSOR crsNew		
	
SELECT 	surv_sca
APPEND FROM (DBF("crsNew"))
>I think this is an easy one, but I have yet to figure it out.
>
>See the following code in my Form Init. The code scans records in a master table and adds records to a sub table if they are not already in the sub table.
>
>Whenever I run the form it adds records to sub table even if records already in sub table? Something is wrong with the SCAN FOR command. Thanks.
>
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform