I am going to try this one last time at the risk of being flogged or drawn and quartered, only because the previous suggestions never worked - Here is what I am trying to do, I have 2 colon delimited "/etc/passwd" like files with a unique key at the beginning of each line on each one, the second file is a subset of the first or master file, i need all of the files from the subset matched up with the same keys in the master file and the rest of the master listing concatenated onto the end of the subset keys listing, see below:

File 1 - master list key1 other stuff key2 other stuff key3 other stuff ... File 2 - subset listing key1 more stuff key3 more stuff ... Desired result: File3 - final listing - subset listing with matching k +eys from master listing concatenated at end key1 more stuff other stuff key3 more stuff other stuff

Thanks in advance


In reply to subset extraction from master file by tux242

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.