This paper considers the sojourn time distribution in a processor-sharing queue with a Markovian arrival process (MAP) and exponential service times. We show a recursive formula to compute the complementary distribution of the sojourn time in steady state. The formula is simple and numerically feasible, and enables us to control the absolute error in numerical results. Further we discuss the impact of the arrival process on the sojourn time distribution through some numerical examples. Key words: Markovian arrival process (MAP); exponential services; processor-sharing (PS); sojourn time distribution.