In 980, the Song dynasty of China under Emperor Taizong ordered a Chinese army to invade Đại Cồ Việt.
Because the young emperor was unable to lead the country against the invader, the mandarins of the imperial court discussed with Empress Dương Vân Nga about enthroning the most trusted general and regent, Lê Hoàn.
Lê Đại Hành's army met the combined forces of Champa, Chenla and Abbasid Mercenaries in Đồ Bàn, (Quảng Nam province today) and be able to defeated all of them.
[4] Some domestic achievements of Lê Đại Hành include constructing new monuments and galvanizing agricultural and handicraft production in order to make economic progress.
He also supervised the national economy and began the construction of bridges, roads, and other infrastructure for easy transportation of people and commodities, especially water.
"[5] Despite his supposed achievements in diplomacy, religion, infrastructure, and the economy, Lê Long Đĩnh's rule was characterized by debaucheries, wild orgies, and decadence according to ancient sources, although modern historians have dismissed these stories as legend, while other historians compare him to the Roman Emperor Nero as he was well known for his cruelties, not the least of which was sadism and torture of not only many types of criminals but also his own relatives, with him only promoting and partaking in these infamous acts.
In 980, Lê Hoàn appointed several men to court positions: Hồng Hiến as the grand chancellor, known in Vietnamese as Thái sư; Phạm Cự Lạng as the vice-chancellor, or Thái úy; Từ Mục as grand governor of court, Đại tổng quản; and Đinh Thừa Chinh as imperial capital interior military commander, in Vietnamese Nha nội đô chỉ huy sứ.
[6] In the ruling era, Lê emperors often faced the revolts of some local Tribal chief and viceroy, especially in remote areas, retaining the specific authorization to quell them.
However, Dương Tiến Lộc opposed it and seized the two provinces, proposing to place them under the control of the Kingdom of Champa, which refused him in order to maintain a friendly relationship with Đại Cồ Việt.
Lê Đại Hành led an army to defeat and kill Lộc along with a general massacre of citizens in those two provinces.
In 1009, the country started the massive construction of transportation infrastructure for trading among the regions and to facilitate travel for soldiers heading south.
The emperor's land was cultivated with a spiritual significance, intended to have the people to take part in agricultural activities, mainly prisoners and peasants, with all products going to the imperial court; it was first implemented by Lê Đại Hành in 987.
Besides that, the government encouraged subjects to exploit wild and untouched land by settling it, providing property at a lower cost while simultaneously expanding its influence in unsettled regions.
The main trade partner of Đại Cồ Việt was China, and both sides agreed to establish bilateral exchanging of goods at borders.
Đại Cồ Việt was a tributary state of the Song during the Early Lê dynasty, maintaining a delicate balance of peace with China and independence.
[3] In 986, Emperor Taizong of the Song dynasty appointed Lê Hoàn as Annan duhu, or Superior Prefect of Annam.
Then he sacked the capital of Cham and captured a hundred soldiers and concubines along with one Indian monk, taking home precious goods such as gold and silver.
In 992, the Champa king Harivarman II sent an envoy to Đại Cồ Việt to ask for the release of 360 prisoners back to the homeland.