A confident, profligate but eventually effective performance sent the Royals through to the knockout stage of the EFL Trophy.