Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Comparing 2 arrays/files

Status
Not open for further replies.

Larshg

Programmer
Mar 1, 2001
187
DK
Hi

I have 2 arrays (or files) and I need to find those names that are i BOTH arrays/files
ex.
array1 contains: name1 name2

array2 contains: name2 name3

The output I need is "name2"

I tryede to find a command like diff, to get the things that are not different - but I can't find an option that will give me that.

Thanks
Larshg
 
Hi Larshg,
what is the structure of your files ?
Only one line with two or more names ?
A lot of lines with two nimes ?
Boris
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top