Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP 3 - Insert into ????
Message
From
23/09/1998 23:16:08
Larry Long
ProgRes (Programming Resources)
Georgia, United States
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00133920
Message ID:
00140191
Views:
23
>>>Does anybody know how to check to see if an insert into from memvar actually worked?
>>>
>>>I have a system that seems to not be storing the all of the records properly.
>>>
>>>i.3. ifthere were 10 to insert, it might only insert 6...
>>> i.e. 1-4 in 5,6 out7 in 8,out, 9 in 10 out...
>>>
>>>
>>>I create a cursor to store the jobs to print. I scan through this cursor and place the records into the main table using insert into...
>>>
>>>Right after this, I print a report, based on the cursor.... (all of the records are there as they all show up in the report.) However, some of them don't get added to my table.
>>>
>>>
>>>Any ideas,
>>>
>>>Mike
>>You might try checking the reccount() after each insert, perhaps something like..
>>
>>select yourtable
>>=flock()
>>store reccount() to m.records
>>
>>insert into yourtable from memvar
>>
>>*force reading of current table header
>>=rlock()
>>unlock
>>
>>if reccount()<=m.records
>> wait window 'Insert was not successfull'
>>endif
>
>
>Seems like the =rlock(), unlock has done the trick.. it has been two weeks and no lost records.. Mucho thanks
>
>Mike
Glad to help. I ran into this while developing a real-time system under NT. A user was putting information in that other users needed to have available w/in 10 seconds. I thought that the FLUSH command would do the trick, but we were still having problems. After much gnashing of teeth and hair pulling, I tried this and found that it was the only way to ensure that current information was being retrieved. Apparently the FLUSH command is only for ensuring that outbound data is sent.
//:^)
L.A.Long
ProgRes
lalong1@charter.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform