Star Trek The Next Generation: Parallels

Lieutenant Worf returns to the Enterprise in a shuttlecraft from a bat'leth tournament, in which he won first place. When he arrives on the Enterprise, he cautiously enters his quarters, apprehensive that his crewmates are probably going to throw him a surprise birthday party, which he hates. Sure enough, when he arrives at his quarters, the crew jumps out in surprise, with much rejoicing and celebration.
Then odd things begin to occur that only Worf notices. The cake, which was originally chocolate, is suddenly yellow. Captain Picard is attending when Riker had earlier said he couldn't make it. Data's painting, which ship's counselor Deanna Troi had hung on the wall, has changed, and has even moved across the room in an instant. Worf continues to experience all these changes throughout the episode, which escalate in severity; at one point, he suddenly finds himself at his tactical station on the bridge in the middle of a crisis situation.
Worf's jumps tend to introduce and maintain certain themes. Once Riker becomes captain, he seems to stay captain; once the Bajorans and Cardassians switch roles, becoming (respectively) enemies and allies of the Federation, they stay that way; once La Forge is dead, he stays dead. Most significantly, after the third or fourth jump, Worf finds that he is married to Deanna Troi from that point on. (However, the elevation of Nurse Ogawa to Doctor Ogawa, Chief Medical Officer, in place of Beverly Crusher, is not maintained in this way.) Also, his standing in the bat'leth tournament progressively deteriorates; he eventually reaches a universe where he was unable to make it to the tournament at all, and instead asked his brother Kurn to go in his place. On the last Enterprise that Worf jumps to, Worf has the rank of Commander, and is Captain Riker's first officer (Picard having died in that universe during a battle with the Borg); Wesley Crusher is a Lieutenant. Other more subtle changes throughout the episode include the use of insignia pins - seen in Worf's final alternate universe - reused from the episode "Future Imperfect" and in the one alternate universe Data had blue eyes while the new warp core which was featured in "Phantasms" was present instead of the old warp core.
It turns out that Worf's RNA has a different quantum signature than that of the rest of the universe — meaning that he is in the wrong universe. Data speculates to Captain Riker that when Worf was returning from the bat'leth tournament, he accidentally entered a time-space fissure. The warp engines on his shuttle caused a reaction in the fissure, sending Worf into quantum flux through the endlessly branching universes that occur when events in different universes follow different paths. Based on the fact that Worf's quantum jumps during the episode always occur when he is in proximity to Chief Engineer Geordi La Forge, Data determines that Geordi's VISOR must be interacting with the quantum flux in Worf's RNA to cause Worf to jump from one quantum universe to another.
Hoping to find where Worf actually belongs, the crew returns to the fissure and scans it with a subspace differential pulse. While they search, the Enterprise is attacked by a Bajoran ship (in this universe, the Bajorans are an aggressive and hostile empire), and the fissure begins to destabilize. Realities begin to merge into one another, and hundreds of Enterprises appear, so many ships that Wesley Crusher reports, "Sir, we're receiving 285,000 hails." Now outnumbered, the Bajoran ship disengages from battle. Data realizes the only way to stop this phenomenon is to find Worf's Enterprise and send him back through the fissure to seal it. Worf's true Enterprise is eventually located, and he boards his shuttlecraft, re-modulated to seal the fissure. However, another Enterprise attacks the shuttle — an Enterprise commanded by a haggard, delirious Riker, who is desperate not to be returned to his own Borg-overrun universe; this Riker yells, "We won't go back! You don't know what it's like in our universe - the Federation's gone, the Borg are everywhere! We're one of the last ships left! Please, you've got to help us!" in describing the dire situation in that universe. To protect Worf, the Enterprise fires on the other ship, inadvertently destroying it.
Worf soon arrives in his own universe, the fissure sealed, with no one other than Worf left with any memory of the events that just transpired. He returns to his room expecting a surprise party, but instead finds Deanna. She says that Riker wanted to throw the party, but she dissuaded him. As she leaves, Worf asks her to stay so they can have dinner. Deanna appears pleasantly surprised as Worf tells the replicator, "Champagne."