This comes from the soap opera Friends. When Rachel and Ross coming back from hospital about Rachel's pregnancy, Pheobe asked:"So, how was the doctor?"

This greeting is very strange to me since I do not think she concerned the doctor who had done the pregnancy test for Rachel.

What can you say about this? Thanks.
"How was the doctor" = "how did things go at the doctor, with the doctor, at the appointment with the doctor". Just informal chat.

When I simply look at the words as written here, Philip's interpretation is what comes to my mind.

To decide if any other interpretation is correct, one would have to actually see the show and hear the words spoken.

Best wishes, Clive
Site Hint: Check out our list of pronunciation videos.
This phrase was not informal chatting. It was a humourous greeting because it was ironic and unexpected.

Consider the situation: All of the friends are gathered around waiting to hear important news about the pregnancy test. But instead of asking for the result, Phoebe inquires about the health of the doctor. As if that was what they were most interested in.

Your intuition was correct. --The health of the doctor wasn't important. That's why the greeting was funny, and it's why the audience laughed. In essence, Phoebe was poking fun at herself. Her greeting would only make sense if she wasn't very smart, not concerned, or was totally confused. --Of course, this wasn't the case, which the friends knew. They understood that was simply and kindly putting her nervous friends at ease.

Explaining a joke, ruins it too. Sorry about that.

But I didn't want you to think that this phrase was simple informal chatting. Instead it's a sophisticated use of incongruity that you can emulate. Afterall, in order to pretend to misunderstand a situation, you first must understand it. Use this form of humor to put your hosts at ease, and to show them that you are both comfortable the limites of your cultural knowledge and capable of understanding complex situations.
 Clive's reply was promoted to an answer.
Students: We have free audio pronunciation exercises.
From what I know of the show:

Rachel is obsessed with dating a doctor...so the greeting could have meant "Did you like the doctor?"

My experience of that kind of show is that the laugh-track machine Emotion: big smile "laughs" Emotion: big smile at just about everything that is said, and so is not a very good indication of what is really funny.