Some possible problems could be that the artist Avenged Sevenfold has a "space" after it, which itunes recognizes as a different artist. It is also possible that under "info" the album artist is differet between the two sets.
Highlight all the songs, get info, and type in the correct info in both the artist box and the album artist box. They should now all be listed together.
1. Highlight all of the tracks and click get info.
2. Check and fill in Artist with "Avenged Sevenfold"
3. Check and fill in Album Artist with "Avenged Sevenfold"
4. Check and fill in Album with "Nightmare"
5. Check and fill in Track Number (blank) of 12
6. Check and fill in Disc Number 1 of 1
(By check I mean to make sure the box has a check mark)
That should do it. Your's in kinda strange though because I bought the album from iTunes as well and it's all the same for me.