Does DELETE close a lookup?

Jay R. Ashworth jra at baylink.com
Sun Dec 2 17:15:31 PST 2007


On Sun, Dec 02, 2007 at 05:48:12PM -0700, fp at casabellagallery.com wrote:
> Jay posted:
> [ snip ]
> > 
> > Well, I guess that proves that DELETE doesn't imply CLOSE.
> > 
> > I believe that to be a bug.  It's especially a bug if I can't CLOSE
> > *after* I delete: I'm going to have code working against that alias
> > tag, and I don't want it to blow up if I've had to delete the record
> > (which I won't always do...)
> 
> I added a 'close' command and delete several records without an error.

What's "an error"?

> Of course, I do not know if you are referring to possibly creating a
> problem and causing a segmentation error down the road ... ???

Nope; see below.

> Again, the close command closes the alias not a record.  'delete' deletes 
> a record, not the alias (which would be the file itself).

OK.

lookup alias=filename k=whatever -nx

alias is supposed to be true, if the lookup succeeded, and false, if the
lookup failed.

If I close the looked up file, or delete the looked up record, *I*
would expect the truth value of that alias to become false -- since it no
longer represents a successful lookup.   If it doesn't work that way, I
see no way one could avoid executing lines which use fields from the
target file.

You've (tentatively) proven that this is not the case for DELETE -- it
still returns true, even though that tag now fails to point to a valid
lookup record.

If you're telling me that the alias remains true once a valid lookup
has been done *even if that file is then CLOSED* (close ALIAS), I shall
be still less pleased.  :-)

Cheers,
-- jra
-- 
Jay R. Ashworth                   Baylink                      jra at baylink.com
Designer                     The Things I Think                       RFC 2100
Ashworth & Associates     http://baylink.pitas.com                     '87 e24
St Petersburg FL USA      http://photo.imageinc.us             +1 727 647 1274

	     Witty slogan redacted until AMPTP stop screwing WGA


More information about the Filepro-list mailing list