Hi,
I might consider saving the database natively as a REBOL hash, only updating
it as needed from the database using the script you wrote. I would imagine if
you could get away with doing this it would save a ton of time.
--Ryan
[EMAIL PROTECTED] wrote:
> Hi REBOLers:
>
> Among many other REBOLian projects, I am putting my ref book, THE SANDERS
> PRICE GUIDE TO AUTOGRAPHS on line. It has over 80,000 prices. Until
> REBOL/command is available and I can use mySQL, I've got the info on the
> server as a tab-delimited text file. I read it into REBOL via this
> technique:
>
> a: read/lines %auto.db
>
> a: to-hash a
> b: []
>
> random/seed now/time
>
> repeat count 10 [append b pick a (random ((length? a) - 10))
> ]
>
> You can a test of this in action (getting 10 random lookups every time
> Refresh is hit) at http://abooks.com/cgi-bin/randauto.r.
>
> My question: can anyone suggest a more efficient way to doing this?
>
> Thanks,
>
> --Ralph Roberts
> REBmeister,
> ALEXANDER BOOKS