DS9 really did comedy well. Unlike the funny but often garish Ferengi-centric episodes, this one feel much more natural. Riffing on Cyrano de Bergerac and developing an almost Shakespearean tilt, this is an absolutely wonderful episode about lust and romance in all its various forms.
The jokes just work, and so much of it is because the comedy all stems from characters rather than just situations. From over-the-top stuff like Worf throwing Morn aside and challenging Thopok, to subtle things like the girlish (and very un-Klingon) yelp from Grilka when Quark pinches her on the way down from the holosuite. The actors sell it, too, for example the excellent ending when Julian realises what his multitude of patients have been getting up to.
Then we have the O'Brien/Kira storyline. On the surface this is very strange and something that I wouldn't have thought works for the characters at all - and it doesn't, that's entirely the point. They're both equally as horrified with the sudden thoughts in their heads, and again it's played so well that even though we as an audience think, "noooo!", the show recognises it.
Certainly among the funniest episodes of the series, but it also gives us so much great character work. Finally, after a year, Jadzia manages to get Worf to see that she's been standing there the whole time!
Very good take on the Cyrano de Bergerac story. And the end....well ;-)