I'm going to admit straight up that I'm lost. I haven't programmed in over 20 years and that was in Basic and some Pascal.

I've tried what I think is everything. Here's what I'm looking to do, either line by line or slurping, whatever.

I've a large text file, hundreds of Mb usually. I'm looking for specific data in lines that appear sporadically throughout the file. The only constants that appear in the specific lines are "ccParty<XXXX>", "Port<X-X-X-X", and "DTMF<X>" where X is a number in either decimal or hexidecimal form.

The entire line looks like:

2011-12-21 00:24:20.423024%%0f-1f-16%%DB1%% ccParty<0x31A9A> Port<1-14 +-7-23> DTMF<4>

All I'm trying to do is find those specific lines and have the entire line print. I can never see any results so I can never tell if the code is working even if I get no errors.

My test scripts have become so convoluted that I don't know what I should put up here for critique.


In reply to Perl = Greek to me by smolikmd

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.