Creating unique numerical representation of file path?
Creating unique numerical representation of file path?
- Subject: Creating unique numerical representation of file path?
- From: Richard Rönnbäck <email@hidden>
- Date: Sat, 13 Oct 2007 07:33:11 +0200
- Thread-topic: Creating unique numerical representation of file path?
I am working on a project where I prepare text files for import into
FileMaker Pro. The text files contain various fields but the idea is to use
the file path act as the matching field on import.
The problem is that FileMaker's matching mechanism has a limit of something
like 120 characters, which means that file paths longer than that are
inaccurately matched and imported into the wrong records, and even into
multiple records
I know how to work around this issue by using scripts and loops and external
comparisons, but the problem is performance, the import files may contain up
to 50,000 records and may be imported up to 50 times a day.
A second related consequence of FM's limit is when creating relations, so I
would need such a short representation for that reason too.
So now I wonder if it would be possible to create a unique numerical
representation of a file path, that would be shorter than the file path
itself, but as my mathematical skills are far to basic I am hoping to get
input from someone with better knowledge of math than me.
So, how can I turn something like this:
/Some/Very/Long/POSIX/Path/
into a shorter number like this
1234
And be absolutely sure that no other path/sequence of characters could get
the same number?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden