Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Get checksum/fingerprint of large character strings
Message
From
19/01/2002 13:58:30
 
 
To
18/01/2002 14:12:00
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00606761
Message ID:
00607329
Views:
22
Thanks Hilmar. It looks like Lauren's suggestion might do what I need.

>>Hilmar,
>>I haven't run extensive tests. But since SYS(2007) returns a value between 0 and 65,535, it's not reliable. ...
>
>Yes, I thought about this while coming home today.
>
>>Unfortunately, I cannot use filename and timestamp. I came accross identical files with different timestamps.
>
>OK.
>
>>I think a function similar to SYS(2007) but with a much wider range would do the trick. I was hoping that somebody knows an API function that would do this.
>
>Another problem with your approach is the time it takes.
>
>May I suggest the following alternative, or, rather, variation:
>
>Take four checksums, of segments of 10,000 bytes each, starting at positions 0 (or is it 1?), filesize * (1/4), filesize * (1/2), filesize * (3/4).
>
>This would reduce the probability of repeating values considerably - unless the files have large segments of repetition, like
>
>This gives you a total of 8 bytes (2 for each checksum, if you use bintoc()). Include the filesize, too, for additional safety (another 4 bytes).
>
>I don't know about API alternatives.
>
>HTH, Hilmar.
Daniel
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform