tobold.org

correct • elegant • free

△ comp.lang.perl △

◅ dbm error and weirdness

File opening problem. ▻

DBM under Perl 5

In article <4i5b8n$3l4@sphinx.Gsu.EDU>,
Michael David Ivey <ivey@gstv.gsu.edu> wrote:
>I have some code (perl4) dealing with the dbmopen function that won't
>work under Perl5.

In what way doesn't it work?  Can you show us a snippet of code that
demonstrates the problem?

>                              It's basically opening a dbm file, but
>dbmopen is screwy.

In what way is it screwy?

(I'll bet anyone a pound to a penny that Michael has never worked
in tech support.  I guess mechanics ("my car doesn't work properly")
and doctors ("I'm ill") must have the same problem.)

>                    I have seen something about tie(), but don't
>know where to begin.

tie is the generalized mechanism for "magic" variables that was
introduced in Perl 5, and is used to implement dbmopen behind the
scenes.  By using the tie instead of dbmopen, you get a bit more
control over what's going on, but dbmopen should work exactly the
same in Perl 5.

Tim.
--
Tim Goodwin   | "Those who will not study history are
Cambridge, UK | doomed to debug it." -- Barry Shein

Original headers:

From: tim@pipex.net (Tim Goodwin)
Newsgroups: comp.lang.perl.misc
Subject: Re: DBM under Perl 5
Date: 14 Mar 1996 17:53:40 GMT
Organization: Unipalm PIPEX
Message-ID: <4i9mf4$80p@wave.news.pipex.net>
References: <4i5b8n$3l4@sphinx.Gsu.EDU>

△ comp.lang.perl △

◅ dbm error and weirdness

File opening problem. ▻