'More duplicate records in the merged file than original files after joining two files

I combined two large text files with join (join -1 2 -2 1 --header file1 file2 > combined-file). In both "file 1" and "file 2", some identical records (lines) are duplicated, say we have 8 duplicated records in "file 1"; the same records are also duplicated 8 times in "file 2". I expected that the "combined file" must have 8 duplicate records, but it had 64 duplicate records!! I did not want to remove duplicate records during joining two files. Could you please share your idea why there are 64, not 8, duplicated records in the "combined file"? is anything wrong with my join command?

Thanks



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source