Maybe the Standard & Poor's downgrade of the U.S. sovereign debt rating is roiling markets and causing China to double down on efforts to diversify its massive cash hoard away from U.S. dollar holdings, but last week's resolution of the debt-ceiling crisis has been good news for the money market fund industry.

After a scary week leading up through Aug. 2 in which investors pulled a record $103 billion  out of money funds on concerns that the government might default on its debt, money market funds last week took in $46.5 billion for a net gain of $9 billion for the week ended Aug. 5. 

Peter Crane, a principal at Crane Data LLC, told On Wall Street that on Friday alone, money funds took in $8.5 billion in cash deposits, with the trend of large inflows expected to continue this week.

The outflow for the week leading up to the Congressional debt ceiling resolution, while lower than the record outflow of $120.4 billion in the week ended Sept. 23, 2008 during the financial collapse, was actually higher as a percentage of total assets in money market funds. The 2008 outflow was 3.5% of assets in a week, while the week ended Aug. 2 this month represented 3.9% of the total of $2.63 trillion in invested assets at money market funds.

Crane reported that most of the money withdrawn from the funds went into banks, with so much flowing into Bank of New York Mellon, the nation’s major clearing institution, that the bank announced it was charging depositors of over $50 million in cash a fee of 0.13% interest on deposits.  The bank said the fee was to cover its costs in buying insurance for the interest-free deposits.

Banks are allowed to insure business deposits. The fee would be removed later, the bank said, as money began moving back into money funds.

According to a Wall Street Journal report, most of the money pouring first out and then back in to money market funds was coming not so much from individuals as from corporate treasuries and institutional investors.