What was common is that they were both fought as plans of Lee to move the fighting no Northern Parts of the federation. Antietam ended in a draw, while Gettysburg became a victory for the Union.
To end World War 1, and to have Germany pay reparations for causing the war.