This is as brief as the Random House Unabridged Dictionary can get it:
which, ****. 1. what one?: Which of these do you want? Which do you want? 2. whichever: Choose which appeals to you. 3. (used relatively in restrictive and nonrestrictive clauses to represent a specified antecedent): The book, which I read last night, was exciting. The socialism which Owen
'That' is restrictive only: The hat that I bought is too large. 'Which' can be either restrictive (The hat which I bought is too large) or non-restrictive (This hat, which I bought in LA, is too large).