According to Wikipedia:
France began work on the canal in 1881, but had to stop because of engineering problems and high mortality due to disease. The United States took over the project in 1904, and took a decade to complete the canal, which was officially opened on August 15, 1914. One of the largest and most difficult engineering projects ever undertaken, the Panama Canal shortcut greatly reduced the amount of time taken for ships to travel between the Atlantic and Pacific Oceans, enabling them to avoid the lengthy, hazardous Cape Horn route around the southernmost tip of South America via the Drake Passage or Strait of Magellan. The shorter, faster, and safer route to the U.S. West Coast and to nations in and around the Pacific Ocean allowed those places to become more integrated with the world economy. The approximate time to traverse the canal is between 20 and 30 hours.