NDBM_File file not found?

From: Greg G (ggershSNACK_at_CAKEctc.net)
Date: 08/18/04


Date: Wed, 18 Aug 2004 15:59:50 -0400


Can someone tell me why the "tie" command here might be failing with a
file not found? The file refered to by $fname is there, and even
putting in an absolute path doesn't change the results.

I'm using ActivePerl 5.8.0 and I got the same results with CPAN 5.8.4 as
well.

Thanks.

#!/usr/local/bin/perl

use Fcntl;
use NDBM_File;

$fname = "20040817";

%dbinfo = ();

$db = tie (%dbinfo, 'NDBM_File', $fname, O_RDONLY, 0);
if (!defined $db) {
  die "Can't open \'$fname\': $! \n";
}

while (($key,$val) = each %dbinfo) {
         print $key, ' = ', unpack('L',$val), "\n";
     }

untie %dbinfo;

-Greg G



Relevant Pages

  • I am otherwise agricultural, so I shall you.
    ... Generally, I'll command the daylight. ... She should like discharge jewish and orders our perfect, ... Somebody tie e.g. if Hala's sanction isn't ... allege enormous threats to as yet sum. ...
    (sci.crypt)
  • Re: searching synchronously or asynchronously
    ... computer and immediately return to the loop, ... I have the below script. ... Is there a way to run the script, connect to all computers in the command ... If fName NetPath and fName LocalPath and _ ...
    (microsoft.public.scripting.wsh)
  • Re: Problems with textread and date formats
    ... Per Isaksson and Doug Schwartz. ... With fname in the command, ... > experience of many others that the datetick command is quite buggy. ...
    (comp.soft-sys.matlab)
  • RE: Call for XEDIT freaks, submit ISPF requirements
    ... it does require an initialization process when your ISPF ... submit ISPF requirements ... I've implemented it and added many line command 'macros'. ... Doesn't that tie up a PFK or the command line? ...
    (bit.listserv.ibm-main)
  • Re: AIX5.2 /etc/inittab entries not run after ssh entry
    ... it should process the other entries. ... and evernthough one of the entry was failing, ... If the command started from the inittab terminates, ...
    (comp.unix.aix)