Complex sentence: During the Mexican American War of 1846-1848, he served for two years as Lieutenant Commander on board the USS Independence (1814) which served as the flagship for U.S. Navy Pacific Squadron Commander, Commodore William Shubrick.
Split into simpler sentences: During the Mexican American War of 1846-1848, he served for two years as Lieutenant Commander on board the USS Independence (1814). This ship served as the flagship for U.S. Navy Pacific Squadron Commander, Commodore William Shubrick.