Hello,

I am a research assistant and decided to learn perl so that I can better collect data. One recent task that has perplexed me is how to check the validity of data i "ripped" from a webpage. I just figured out how to parse data and have made 1000s of CSV files. I worry though that the website might have an imperfect mechanism of generating replies to queries.

Here's what I want to do. I want to check whether all of my files are different. The problem is... there are about five thousand of them.

How can I write a perl script that would open one up, read the first line of data and then compare it to the first line of every other file. How can i do this without comparing.

20040819 Edit by broquaint: Changed title from 'question about reading massive number of text files'


In reply to Verifying data in large number of textfiles by dchandler

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.