John Tyler was the only US president elected to serve two different governments, the Union, and the Confederacy.