UK midcaps rise on upbeat earnings; energy stocks drag FTSE 100