Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
List of open tables
Message
De
05/12/2014 09:49:41
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01611852
Message ID:
01611895
Vues:
79
>What is a best way to get a list of OPEN tables?
>
>I need to get a checksum of the current record in every currently "open" table.
>Either in an array or a table, so I can then use the SYS(2017) function to get each checksum.
>
>Then I will add them up to come up with a single Combined Checksum

Hi,

if you want to be make sure the data set is not being repeated you could also execute an SQL statement like:
SELECT KeyField, Recno() as Rec ;
  from YourTable ;
  Where KeyField in ;
    (SELECT KeyField ;
        from YourTable ;
        Group by KeyField;
        Having Count(KeyField) > 1);
  Order by 2, 1 ;
  Into Cursor DuplicateRec
seems, to me a lot easier than this checksum manipulation, besides sys(2017), I believe constructs a checksum with aid of your pc's time(miliseconds) so likely two or more fields with repeated values will receive different checksums, should need some testing to confirm this.

Regards,

Koen
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform