SNW is considerably better at comedy on its worst day than TNG ever was. And I say that as a TNG fan. By the same token, I wouldn't put all of SNW's efforts at the apex of Trek comedy form.
I mean if a 40 year old show is your tutor okay but I don't think TNG ever did outright humour did it? As it knew itself. It had humourous moments though.
TNG attempted quite a few comedic episodes. Rascals, Up the Long Ladder, Data's Day, The Naked Now, The Royale, The Devil's Due, many of Q's appearances (like Qpid), and basically whenever Lwaxana Troi showed up. Many of those were a bit stiff and ill-judged and fell flat (especially the ones centered on Lwaxana, who was an intolerable narcissist and not the charming, effervescent Auntie Mame type they were aiming for).
Berman-era Trek did eventually get the hang of comedy. DS9 in particular proved to be a lot better at it, and Voyager and Enterprise (say what you will about them more generally) had some fine comedic outings of their own. TOS likewise was often funnier than its successor.
I'm not sure where I'd rank SNW's wackier outings among those examples. In episodes like The Trouble With Tribbles or Take Me Out to the Holosuite or A Piece of the Action or Bride of Chaotica, the comedy flowed from very simple, straightforward set-ups that made sense on their own terms. That's an admitted advantage by comparison with SNW outings like Four-and-a-Half Vulcans or even like this one, where the setups become less and less straightforward (or even explicable) as the story progresses. And, indeed, the better bracket of Wacky SNW episodes also spring from simple, compact concepts.
Still, the comedic gifts and sheer charisma of the SNW cast -- along with a more contemporary style of humor -- often do a lot of carrying. That's a big part of what really shines in this episode, making its "The Hangover-in-space" premise a lot more palatable than it would otherwise be. (Of course, you have to
like The Hangover to get into The Hangover-in-space, but I have no issue with that. Many an episode of Trek has derived its quality by borrowing from other shows and movies.)