Circumvesuviana Enquiry

G'Day, 19M solo interrailing, I have planned to go from Naples to Sorrento via the Circumvesuviana train, I just want to know if I can get off at Pompeii with my ticket to Sorrento and explore Pompeii for couple of hours, and get back on the Circumvesuviana express with the same ticket and go to Sorrento? Or do I have to book separate ticket for my Journey from Pompeii to Sorrento? Thanks in advance