S&P 500, Nasdaq end at records after upbeat business surveys