Operating System - HP-UX
1752777 Members
6275 Online
108789 Solutions
New Discussion юеВ

Re: unique comparison 2 fields,

 
SOLVED
Go to solution
rmueller58
Valued Contributor

unique comparison 2 fields,

I am wanting to LOOK AT information from two columns:
Where the values in the two columns both are valued I want to ignor.

where the value in Column #1 (FS) exists but not in #2(DB)

I want to echo that value to a flat file for using in STDIN.


FS DB
1001
1002
101
1010
1012
1027 1027
1028 1028
1032 1032
1033
104 104
1040 1040
1045 1045
1048 1048
1049 1049
1054 1054
1062 1062
1063
1065 1065
1066 1066
107 107
1077 1077
1080 1080
1086
1087 1087
1090
1096 1096
11
1100 1100
1106 1106
1108
1109
1112 1112
1113
1115
1116 1116
1124 1124
2 REPLIES 2
James R. Ferguson
Acclaimed Contributor
Solution

Re: unique comparison 2 fields,

Hi:

Perhaps:

# awk 'NR>1 && NF==1 {print}' file

Regards!

...JRF...
rmueller58
Valued Contributor

Re: unique comparison 2 fields,

Thanks James,

It has been a long week.. I couldn't wrap my brain around it.. That did the trick..