#!/usr/bin/perl -w use strict; use DB_File; $| = 1; unless @ARGV { die "No filename argument provided"; } my $file = shift @ARGV; # here's this line again: tie my %IDS, "DB_File", $file or die "Can't open $file: $!"; # and this block is the same as I used for testing above for (keys %IDS){ print "\n\n$_:\n"; for my $key (@{$IDS{$_}}){ while (my($k, $v) = each %{$key}){ print "$k => $v\n"; } } }