Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Update Table from Network
Message
De
10/09/1999 21:20:30
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00263445
Message ID:
00263580
Vues:
19
>I am getting data dump on my network from another location. How do I check if a new file has been received periodically in foxpro and is there a command that will update my table based on record key only the fields that have changed? Also will the update interfere with users already using the tables? Help appreciated
>

Start a timer; in the timer event, check if the file is present/changed (you can use the FILE() or ADIR() command to see if the file is present, and you can check the file's date/time stamp with ADIR() or FDATE() and FTIME() if the file is always there but you need to see if the file has changed since you last checked it (you'd need to track last check time to do this.

You can update records easily enough, but you need to know exactly what changed somehow. You could add a field to the incoming table that gave you a map of what changed in the record and use that for processing, or you could compare field values and update just the fields that differ. Or you could just update everything; if you are logging changes, this would seem to be easiest to do.

Rather than a sinle command, I'd probably write a small piece of code that spins through the records and updates as needed.



>
>thanks
>Nick Patel
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform