Data served aboard the U.S.S. Trieste, which fell through a worm hole and miraculously came out on the other side unharmed. Data is currently an operations manager with the rank of Lieutenant Commander. He is also the science officer and 3rd officer aboard the U.S.S.Enterprise-D. During this time, Data made history in 2368, when he became the first android captain. During the Klingon civil war, he was put in charge of the U.S.S. Southerland. He encountered prejudice at first but eventually gained the crew's respect after inventing an ingenious plan to detect an incoming Romulan fleet which was a threat to the Federation.
Data's rights as a sentient being were questioned when Bruce Maddox, the sole member of the committee to oppose Data's entrance to Starfleet on the grounds that he was not a sentient being, wanted to disassemble Data and construct more androids like him. Data objected to the procedure because his memories and the essence of who he was might be lost during the testing. Maddox insisted and ordered Data be transfered to his command and then ordered Data to undergo the testing. Data refused and decided to resign from Starfleet. Maddox said that Data could not do this because Data was property of Starfleet. A hearing was held and in the end, Data was found to have the same rights and privileges as other sentient lifeforms, including the right to resign from Starfleet. Once Maddox found that he had been beaten, he let Data return to the Enterprise where Data stayed on in his previous position.