Have you tried writing any perl code yourself for this? Can you work out the code that would perform something like this step-wise method:
get the list of file names declare a hash for output open the first file while reading each line from the file get the first column of the line for use as a hash key assign the line as the value of hash element using that key for each remaining file open the file while reading each line from the file get the first column of the line for use as a hash key append the line to the current value of the hash element using + that key for each key in the hash print the value of the hash element using that key
See what you can do. If you have trouble, show us the code you tried, and we'll be able to help out with the details.

(I'm hoping I understood your task correctly -- if I didn't, please clarify.)

UPDATE: Actually, the method can be stated even more simply than what I showed above. In effect, you can leave out the part that handles the first file separately, and just do the "for" loop over all files in the list -- i.e. just treat all files in the list the same way.


In reply to Re: join mutiple files on first column by graff
in thread join mutiple files on first column by david_lyon

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.