I've always been confused over how these work. like, should it be, They wrote a song that was a hit. or They wrote a song which was a hit. And are there any specific rules, strictly referring to the usage of which should be used when? Somehow, our language books never quite specified that.