The train in question is the circumvesuviana train, which is not the same as other trains, especially longer distance train. Those trains would be fine, but the particular train in question is different. It's not that bad, but you do need to be aware that it is a different thing. It's a local train, connecting people around the Naples area, in that way it functions more like the NYC subway than a train for longer travels, and it isn't the newest/cleanest. Some travelers are fine with it, some are not. The hotel is probably used to the latter group and finds it safer to suggest transfers.
So, my opinion - I've taken the train, but not for a stay in Sorrento - for day trips only. It is fine for that purpose, but I would be hesitant to take it with luggage and jet lag. It is crowded and there have been reports of theft. I personally would do a transfer to/from the airport due to luggage - even a carry on size suitcase would be annoying to squeeze in. I wouldn't be hesitant to take the train for day trips to Pompeii or into Naples. That said, if your budget doesn't permit a transfer, the train is not a disaster. It will be fine, just be aware of pickpockets and don't expect much in the way of amenities like A/C or possibly a seat if it is too crowded.