setNames( aggregate(Data$Y,Data['X'], paste, collapse=" "), c("XX","YY"))
XX YY
1 22 123 234 567 678 433
2 33 555 664 77 88
Looks like your grouping was off.... at least as far as I could parse your intent. The English sentence at the end didn't make much sense to me anyway, because the phrase "added after" was unclear.