Capabilities: RTF editing, Graphs, flat-file database

J. Landman Gay jacque at hyperactivesw.com
Tue Jun 8 11:16:11 EDT 2004


On 6/8/04 3:45 AM, Geoff Caplan wrote:

> Sarah Reichelt wrote:
> 
> 
>>>Another very popular way is to use a single data field with one line
>>>per record, and each field in the record separated by some delimiter,
>>>usually tab. The whole field can be loaded into memory allowing very
>>>fast searching, sorting etc.

And yet another way is to store your data as plain (or encrypted, if you 
prefer) text files on disk. Read them into RAM when the stack opens, 
convert them to an array, and work with the array while the stack is 
open. Then reconvert the array back to a text file and re-write to disk 
when the stack closes. Array access is lightening fast if you know what 
key you want, and arrays have no problem with tens of thousands of entries.

You'd have to test the search speed. I have used this approach for 
small-ish databases (5,000 records or so) using the "repeat for each 
element" structure and it wasn't too bad. Not a speed demon, but not bad.

Commands you would need are: split, combine, repeat for each element, 
and the open/read/write file commands (or else the URL container 
structures.)

-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com


More information about the use-livecode mailing list