At the end of 979, Vietnamese emperor Đinh Tiên Hoàng and crown prince Đinh Liễn of Đinh dynasty were assassinated. In May 980, the Song dynasty ambassador to Đại Cồ Việt reported this incident to the Song emperor. In August of 980 Hou Renbao, Governor of Nanning, requested the Song emperor for permission to invade Vietnam. Emperor Taizong accepted this.
granted Hou Ren Bao as admiral and prepare the facilities head to Vietnam. Besides that war message also sent to Đại Cồ Việt with aim that they wish to restore the rule of Đinh dynasty although their ambition was to intervene in Vietnamese politics.
Đại Cồ Việt's house ruling change
The Đinh dynasty of Đại Cồ Việt had successfully sought out and developed diplomatic relations with the Song dynasty of China. After the death of emperor and crown prince, the third son of Đinh Bộ Lĩnh was Đinh Toàn took the throne at 6 years old. The emperor was too young to lead the country so Lê Hoàn was positioned as regent and commander in chief. The Song dynasty of China was inclined to send their military forces to restore the throne to the Đinh dynasty. The threat of a Chinese intervention caused the Đinh court officials to worry about the survival of their independence, so the officials urged Lê Hoàn to become emperor and establish a stable government. In autumn 980, Governor of Lạng province announced the emergency news to Đại Cồ Việt royal court about the oncoming Song invasion, the court was put in the crisis, then the mother of emperor, Empress Dương Vân Nga decide to take the fate of nation. In 979 she enthroned Lê Hoàn as the emperor in exchange Lê Hoàn asked her to be his wife. Although this deal opposed to the tradition, the empress accepted the request and Lê Hoàn accepted to lead the country. In 980, Lê Hoàn proclaimed as the emperor Lê Đại Hành and Đinh dynasty was replaced by Early Lê dynasty. Immediately, he made the nation ready to face the invaders, deploying army, boat and archers and send the envoy to show the peace letter to Song dynasty and said that he will be the next ruler of nation. Song dynasty did not accept it and they just regarded only Đinh dynasty was the legitimate government of Đại Cồ Việt, thus Song refused to accept the letter. Failing to save peace, Lê Đại Hành must let war happening.
War preparation
Song dynasty
Song nominated set up Military expedition in which Hou Ren Bao was nominated at commander in chief, leading both land and naval infantry. Most of the corps were from the local guards and soldiers stationed in South Chinaand 10 to 20,000 was deployed from Song royal courts. The total was 30,000 to 40,000 soldiers.
Early Lê dynasty
In Đại Cồ Việt side, Lê Đại Hành was the leader and commander in chief and The chancellor Hồng Hiến and vice chancellorPhạm Cự Lạng helped to deploy army including soldiers and civilians together against Song's army. Strategic planning was done by emperor, Pháp Thuận and Ngô Chân Lưubuddhist monks. Lê Đại Hành command the main infantry himself from capital Hoa Lư to battlefield by waterway from Đáy river to Red river, then head to the northeast. After that, they started to install the guard around Thái Bình province. Trần Công Tích got mission to defend Nghĩa Đô where was nearby Đại La. The estimation of Đại Cồ Việt force was approximately 10,000.
Result
Đại Cồ Việt got the victory and Song army had to retreat back to China. Most of Chinese historical records about the early of campaign were quite clear, but the records of loss was very vague. Xu Zizhi Tongjian records written by Li Tao demonstrate about the all commander and generals from all ranks were faced the punishment because of war loss. Most of them were executed and some others were demoted to lower ranks, some were killed in the battle field or missing. Consequently, Song dynasty accepted the continuity of Vietnamese independence and recognised Lê Hoàn as the emperor of Đại Cồ Việt. Both nation started to renormalise the diplomatic relation. Đại Cồ Việt accepted to pay tribute once in two year to Song to gain peaceful relation.