I want to create a file that contains columns from two input files. File1 is like:
s,a
k,b
h,c
File2 is:
f,a
g,b
The output should be like:
s,a,f
k,b,g
h,c,-
am using the join command like
join -a1 -a2 -t , -1 2 -2 2 -o auto -e "-" file1 file2 > joinoutput
am getting out put like
a,s,f
b,k,g
c,h,-
please help me to fix , I cant able to specify the order of column like -o '1.1' like. if in my first file number of column is n and second file it is n i need to see n+n -1 thanks in advance
-osyntax, for example for n=3, would it be, "1.1 1.2 1.3 2.1 2.3" or "1.1 1.3 1.2 2.1 2.3" or something else? I think we may have to build the output format string after looking at the files.