Small business optimism rose in July, NFIB study finds