Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Copying records from one table to another in FPW 2.6
Message
 
To
19/03/1997 14:33:54
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00024865
Message ID:
00024876
Views:
41
>>>I have a routine that copies records from one table to another. Sounds simple, but when APPEND is used, the size of the tables exceeds the available memory and cause a Stack Fault.
>>>
>>>I rewrote it so that the records write over existing records (based on matching criteria) using SCATTER MEMVAR and GATHER MEMVAR and use a INSERT - SQL if more records are needed. The problem is that this takes a long time. I can watch the records being written over. The matching criteria is by State and if I have a lot of states to copy, it is painful. (Even one state is painful.)
>>>
>>Can you do a straight delete, pack, and insert? That should be a lot faster...
>
>I have been warned against deleting and packing becuase of the risk of data corruption. Have you had any experience with this? I am using FoxPro in a client environment with the tables on a server and the front end on the users' PCs. (I may resort to packing even though because the current solution isn't so hot.)

Yes, I do fairly frequent 'mass purges' in server-based tables, and very rarely have had any problems (but always do backups, of course). You'll have to do your packs (and reindexes) at odd hours when no users are on (or schedule regular downtimes with announcements), that's a slight drawback, but I have little choice with huge tables...otherwise it works fine.
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform