Eliminate doubles in a long list field
Dar Scott
dsc at swcp.com
Sat Jun 28 11:04:00 EDT 2003
On Saturday, June 28, 2003, at 09:03 AM, yves COPPE wrote:
>> Yves COPPE wrote:
>>
>>> Hello Ludovic
>>>
>>> here is a script I use to do the job between two flds
>>> Very fast !!!
>>
>> Thanks ! Very fast it's true (20 seconds instead of 2 hours !)
Inspired by Yves function I wrote this:
function removeDoubles theLines
replace LF with "|" & "x" & LF in theLines
split theLines using LF and "|"
return keys( theLines )
end removeDoubles
Add sort() if you want.
You can replace the "|" above with numToChar(3) and it works, but null
causes Revolution to have trouble.
That loses order, though. Do you want to keep order?
Dar Scott
More information about the use-livecode
mailing list