How many hours will it take total?
You need to look at the train schedules and the ferry schedules. The train travel time will depend on the schedule you choose. Allow ten minutes minimum to walk from the train station to the Concordia ferry dock. The ferry ride from Salerno to Positano is 70 minutes. You'll need to do the math to determine your total travel time.
4 or more hours each way - the area will be swamped with people, tour buses, etc -
I too would go to Salerno and then get the ferry or you risk sitting, breathing bus/car fumes on the coastal road for many hours.
This really is not a day trip but people do it - just keep track of ferry times for your return back to Salerno for getting back to Rome