custom property searching speed question

Lynch, Jonathan BNZ2 at CDC.GOV
Wed Mar 2 17:58:06 EST 2005


I am on a dell optiplex GX 270

For each line might get faster - but if I can keep my data stored, at
least partly, in custom properties, that would be very helpful. It's the
whole relational concept. Instead of storing text, a given cell could
store something like {Item 4 of the customproperties[120345] of field
"myTable1"}.


-----Original Message-----
From: use-revolution-bounces at lists.runrev.com
[mailto:use-revolution-bounces at lists.runrev.com] On Behalf Of Richard
Gaskin
Sent: Wednesday, March 02, 2005 5:36 PM
To: How to use Revolution
Subject: Re: custom property searching speed question

Lynch, Jonathan wrote:
> More tinkering and testing of timing...
> 
> I changed the customproperty set so that it contains 500,000 records
> with 3 items in each record.
> 
> Item 1, the name of the element
> Item 2, a bunch of words
> Item 3, a number (100)
> 
> I created a script that gets the sum of column 3 of this data set -
that
> is, it adds up item 3 for each element.
> 
> This script:
> 
> on mouseUp
>   put the milliseconds into M
>   put the customproperties of field "theData" into myArray
>   put 0 into tSum
>   set the itemdelimiter to numtochar(30)
>   repeat for each element E in myArray
>    add item 3 of E to tSum
>   end repeat
>   put tSum into field "output"
>   put ((the milliseconds)-M)/1000 into field "feedback"
> end mouseUp
> 
> produces the correct result in .486 seconds!
> 
> Half a second to sum a column of 500,000 items! 

What kind of hardware are you using?  Tests like that usually take me at

least 2 seconds on my PBG4/1KHz.

Have you tried looping through lines in a combined string? If your 
results are like mine you'll shave another 20% off.

Yep, kinda hard to beat the performance of a RAM-based database when you

have the RAM to architect like that...

-- 
  Richard Gaskin
  Fourth World Media Corporation
  ___________________________________________________________
  Ambassador at FourthWorld.com       http://www.FourthWorld.com
_______________________________________________
use-revolution mailing list
use-revolution at lists.runrev.com
http://lists.runrev.com/mailman/listinfo/use-revolution




More information about the use-livecode mailing list