in reply to Joining two files on common field

if it suits your needs, you can simply do this on the commandline with join as well:
[davidrw@host davidrw]$ join -t , -1 1 -2 4 /tmp/f1 /tmp/f2 upc,qty,product_sku,size,color 840197083284,2,121,LG,Black 840197083291,3,121,XL,Black 840197083307,21,121,2XL,Black
see "man join" for the various options to get the output the way you need it (espically if you want to show unmatched lines)

Replies are listed 'Best First'.
Re^2: Joining two files on common field
by ambrus (Abbot) on Apr 12, 2006 at 12:59 UTC
Re^2: Joining two files on common field
by ch1 (Novice) on Sep 22, 2005 at 23:01 UTC
    I tried join first... well becasue it should have been easy but it returns no output.
      what were your attempts? I got nothing at first because i didn't specifiy the comma delimiter with -t (default is tab)... what i posted above worked and that was the actual output... worth a quick glance of the man page in case the params are slightly different for your system?
        Well.... If I type a few lines of each file out manually, the join works. Otherwise the join returns nothing. In vi I've used the set list to check for special character but there isn't any.
        Any idea what could be causing the problem?