The Dow and S&P 500 closed lower Wednesday, ending a string of gains for the equity benchmarks that have been mostly rising to all-time highs on the back of upbeat quarterly results from American corporations. The Dow Jones Industrial Average /zigman2/quotes/210598065/realtime DJIA -1.34% closed down 266 points, or 0.7%, at about 35,491, the S&P 500 index /zigman2/quotes/210599714/realtime SPX -1.18% closed 0.5% lower at 4,552. The Nasdaq Composite Index /zigman2/quotes/210598365/realtime COMP -1.83% finished the session nearly unchanged at 15,236, as a retreat in yields for the 10-year Treasury note /zigman2/quotes/211347051/realtime BX:TMUBMUSD10Y +1.75% and the 30-year Treasury bond /zigman2/quotes/211347052/realtime BX:TMUBMUSD30Y +1.46% hit lows not seen since July 19, according to Dow Jones Market Data. Lower yields can buoy yield-sensitive sectors like information technology and investment factors like growth. In corporate results, Microsoft Corp. /zigman2/quotes/207732364/composite MSFT -0.15% reported quarterly earnings that shot over $20 billion for the first time, late Tuesday, which helped to limit declines in the broader market and supported the tech sector on Wednesday. Microsoft shares rose 4.2% to $323.17, notching a record close, according to Dow Jones Market Data. Meanwhile, in a surprise move Wednesday, the Bank of Canada said it would abruptly end its bond-buying program and warned of prolonged inflation through 2023, while also signaling it may hike interest rates sooner than expected, the second quarter of 2022.