Yes, if that 2 year period was in the last 4 years.
This is straight from the guide on applying:
Within the last 4 years, if you spent 183 days or more in another country (other than Canada), you must provide a police certificate. You must provide a police certificate for each country where...