in reply to Re^2: hexdump/od/perl question
in thread hexdump/od/perl question

I tested my code, so something doesn't jive. Try adding the following to your code:

use Data::Dumper qw( Dumper ); local $Data::Dumper::Useqq = 1; print(Dumper($line));

Put the print before the tr///d.

Replies are listed 'Best First'.
Re^4: hexdump/od/perl question
by EvanCarroll (Chaplain) on Aug 10, 2007 at 17:52 UTC
    Nice application of data::dumper:
    $VAR1 = "STOCK NO\375--------................... D53006\t\r";


    Evan Carroll
    www.EvanCarroll.com
      That line doesn't add anything to %db — the next gets executed since the regexp doesn't match — so it's not the source of your problem.
        Yes it does, but not as I indented, good catch again.
        Line: $VAR1 = "STOCK NO\375--------................... D53006\t\r"; Regex: /(.*?)[.-]*\t(.*)/ "STOCK NO\375--------................... D3006" => "\r", (if i store key instead of undef)
        The problem here is the \375, the nature of this task will be to hack the regex until it works, but I must figure out how to remove the \375 first.


        Evan Carroll
        www.EvanCarroll.com