IMNSHO Lists in Text Files Suck Hard!

Reason: in case you need to view it or edit it in another program it is hard
to make sense of.

Furthemore, converting 3-dimendional lists into CSV or Tab-delimited text
files is a piece of cake. (Incidentally, both formats can be read by most
spreadsheet apps.)

Pekka

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of Al Hospers
> Sent: 4. hein�kuuta 2001 18:54
> To: [EMAIL PROTECTED]
> Subject: RE: <lingo-l> Database and File IO
>
>
> > I've got a file in a hard disk (fomat "clients.txt"). With an
> > Xtra File IO i
> > get read all the database, but i would like to read only a record.
> >
> > Name      City     Salary
> > Bohanen   Geneva   4567
> > Klein     Bern     389
> > Meister   Lugano   9876
> > Correia   Basel    7055
> > etc...
>
> I prefer to use a list format for databases that I do in text files.
> possibly something like this (untested lingo!):
>
> [ [#name:"Bohanen", #city:"Geneva", #salary:"4567"], [#name:"Klein",
> #city:"Bern", #salary:"389"], [#name:"Meister", #city:"Lugano",
> #salary:"9876"], [#name:"Correia", #city:"Basel", #salary:"7055"] ]
>
> read in the entire list from the text file using standard FileIO.
> reconstitute it as a list using
>
>  myList = value(myList)
>
> then get at the data in the normal way you would for any list. this
> makes things lots easier. the only problem is if it is a really big
> list, then there can be difficulties. of course some may say that if
> it is that big you should be using a real database! <grin>
>
> hth
>
> Al Hospers
> CamberSoft, Inc.
> al<at>cambersoft<dot>com
> http://www.cambersoft.com
>
> A famous linguist once said:
> "There is no language wherein a double
> positive can form a negative."
>
> YEAH, RIGHT
>
>
>
> [To remove yourself from this list, or to change to digest mode, go to
> http://www.penworks.com/LUJ/lingo-l.cgi  To post messages to the list,
> email [EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED])
> Lingo-L is for learning and helping with programming Lingo.  Thanks!]
>


[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi  To post messages to the list,
email [EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo.  Thanks!]

Reply via email to