Data Maps
- Posted by Quality <quality at ANNEX.COM> Jan 30, 1999
- 434 views
First. Bernie thank you! I was amazed at how much code it took to do these definitions in Euphoria but at the same time I was (once again) awe struck by how powerfully flexible Euphoria is --- IF you are willing to put up with the code length. Now, I have read Tor's "Frozen Sequences" & "REVOLUTION", Jguy's large database posting and of course Irv's "Holding Back" and Rob's reply's to all. Obviously as a newbie to this language I was not aware of the namespace or disk issues Irv calls up. After digesting all that text <burp!> I suddenly saw a glaring issue missing from the discussion... The issue of why (and how) structures were originally added to other languages. To begin, a quick reminder that "structures" are also called "records" in other programming languages. Without going into a lot of data processing history lets simply say that data was originally stored in "files" which used fixed length "records" containing fixed length "fields". The exact specifications for these data were called "layouts" and were basically a byte by byte description of the contents of a file. Programmers had to build whole routines to parse data everytime a new file layout was needed. At some point a bright programmer realized that a layout was a kind of stencil and wrote a routine to parse stencils instead of directly parsing the data file. These layout stencils became known as data "maps". ( see an example of a data map in COBOL, the **least** elegant language on earth, at the following link --> ftp://red.cscwc.pima.edu/pub/csc135/mortgage.cob ) Eventually language developers realized that while effective and necessary, maps were not elegant and so the data structure process was integrated into compilers. Today Euphoria is like the early days when programmers have to write customized routines for each file layout. I suspect that it would be VERY easy to wrote a set of mapping algorithms and then we would be closer. But I predict that eventually we will need to look at the best of these mapping algorithms and decide on a means to integrate them into Euphoria directly so that data fields can be accessed with ease.