Past perfect is used when you have two past actions in your sentence that didn't happen at the same time. You use past perfect for the action that happened first.
I had studied English before I moved to Canada.
I had never seen an elephant before I went to India.
I knew where to eat because I had been to Paris before.