Many Cards vs. Lists vs. XML

viktoras didziulis viktoras at ekoinf.net
Sat Feb 16 16:51:54 EST 2008


working with lists is much much faster. XML is just plain flat text file 
with more text to process. If you have large and complex dataset with 
items, children items their relations and properties, then it is more 
efficient to use relational database for data storage and retrieval... 
XML suits best to present data stored elsewhere it is rather like 
"document on steroids" or "interactive document" or "communication/data 
exchange protocol" that can be formatted, trasformed or scripted itself 
(e.g. XHTML) to present data in different ways.

Although it is fashionable to use XML everywhere, including data 
storage, i would tolerate it only in those cases where you have 
relatively small amount of complex data. E.g. like rss feeds that are 
usually limited to 10-15 items. For large amounts of simple data in form 
of key-value pairs ordinary list is possibly the best solution. In all 
other cases use real databases.

The perfect delimiter is tab :-). If you use list and data already 
contains tabs, then before populating the list replace tab with some 
unlikely combination of symbol(s) like "\t" and replace those back to 
tab when retrieving data. Same can be done with multiline data - replace 
return with e.g "\n" for storage and then replace "\n" with return for 
displaying. If you go with relational databases (sqlite, valentina 
etc...) there will be no problems because you won't need to deal with 
any field delimiters then (except those cases where you have to import 
data from delimited text file).

All the best
Viktoras


Russell Martin wrote:
> So, I've been reading up on Rev's XML features and I'm wondering if
> that isn't a better route to go than using lists? Any thoughts?
>
> Also, for those that use lists to store data, how do you handle placing
> multiline data into your list structure?
>
> And, what do you do to deal with data that might contain instances of
> your delimiter before you place it in your list? Or, is there some
> perfect delimiter that I just haven't thought of?
>
> Thanks in advance for your responses.
>
>
>       ____________________________________________________________________________________
> Never miss a thing.  Make Yahoo your home page. 
> http://www.yahoo.com/r/hs
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
>
>
>   




More information about the use-livecode mailing list