Foreign investors mopped up the flood of new issuance by Canadian governments and companies, a sign the nation continues to be viewed a safe haven.

Investors from outside the country bought a net $49 billion of Canadian securities in April, the largest monthly purchases from abroad on record, Statistics Canada reported Tuesday. That included $15.8 billion in federal government bonds, as well as $10.2 billion in federal government money market instruments such as treasury bills, both record inflows. Foreign investors also bought $25.4 billion in corporate bonds.

The unprecedented purchases coincide with a hefty issuance of federal debt by Prime Minister Justin Trudeau’s government to fund spending to support Canadians through the economic shock and shutdowns caused by COVID-19.

“The strong inflows into Canadian debt markets reveal that, even during the height of the crisis in this country, Canada was seen as an attractive place to park funds,” Katherine Judge and Royce Mendes at CIBC World Markets said in a report to investors.

Foreigners were less interested in Canada’s stock market, selling a net $4.9 billion in Canadian equities and investment fund shares in April, the data show.