Foreign investors flocked to Canada in 2017: National Bank