On Thu, Jul 17, 2003 at 09:39:40AM +0100, Jack Campin wrote:
> >>>> Given that ABC is text-line-based, *can* a program go straight to a
> >>>> tune, random-access-like, without having read all the intervening lines?
> >>> random-access-"like"... yes, it's possible. My JedABC has an index mode
> >>> that does what you want; so does BarFly in "Split Screen Mode".
> >> But BarFly will have read the entire file before it goes into split-
> >> screen mode, and I suspect JedABC will have done too.  You would need
> >> something like ISAM to do what Richard is talking about, and I don't
> >> think anybody is implementing ABC software in MVS Cobol or in S3 on
> >> ICL VME.
> [Richard Robinson]
> > Uh ? Are we at cross purposes here ?
> > Read through the file, from 1st line to last line, keep a note of what
> > "global" headers are in force, as each tune is met add these in as
> > appropriate. Dunno about COBOL, I agree C is not the prettiest language
> > for handling text, but surely it's not impossible ? Very simple in the
> > "scriptier" languages, like perl for example.
> 
> May be you didn't write it? but the query I quote in the first two
> lines was about kinds of access that *don't* read through the file.
> Instead, open the file and seek straight to the tune you want.
> Database systems do this sort of thing all the time, but it needs
> an external index.

It was me wrote it ... my point was that, to have that external index,
something must have already read the file, at least once, since
text lines aren't fixed-length records. Keeping an external file
of information about the file would probably make for a complicated
way of dealing with global headers, right enough.

If you want strange and obscure storage systems, have a look at my
perl scripts ( RRTuneBook url / abcscripts ), which implement the ability
to read a file of abc (expanding global headers as they go, of course)
and stash each tune in a separate file, replacing the text in the
original file with a single identifier line, which the tools then handle
as being equivalent to the tune (replacing it where necessary). It makes
managing lists of tunes very much simpler, and you can use "make" to
maintain things that are dependent on the abc ... users don't have to
tangle with it if they don't want to ;)

> 
> > I remember now, I used to split this file into alphabetically-sorted
> > chunks so as to get smaller file sizes [...]  I'm not very keen to
> > reinstate this, but will give it some thought if this issue is a
> > general nuisance. Mac users ?
> 
> It never really mattered.  Anyone who wants it in small chunks will
> have the means to split it up; there have been freeware file split/join
> utilities around since 1984 and umpteen editors and WPs can do it.

That was the basis on which I decided it was too much hassle. I used to
get complaints that it wouldn't fit into peoples' browsers.

-- 
Richard Robinson
"The whole plan hinged upon the natural curiosity of potatoes" - S. Lem

To subscribe/unsubscribe, point your browser to: http://www.tullochgorm.com/lists.html

Reply via email to