The books that comprise the Old Testament canon differ between Christian Churches as well as their order and names. The most common Protestant canon comprises 39 books, the Catholic canon comprises 46 books, and the canons of the Eastern Orthodox and Oriental Orthodox Churches comprise up to 51 books.
The 39 books in common to all the Christian canons corresponds to 24 books of the Tanakh, (also called the Mikra or Hebrew Bible, the texts are mainly written in Hebrew, with some passages in Aramaic (in the books of Daniel, Ezra and a few others). The Tanakh consists of twenty-four books.)
There are some differences of order in the Tanakh, and there are some differences in the text. The different number of books reflects the split of texts in the Christian Bibles into separate books, for example, Kings, Samuel and Chronicles, Ezra–Nehemiah and the minor prophets into separate books.
The actual dates of these writings are in dispute, but the best accounts for the dates are arguably as follows..
The entire Old Testament was formed in stages, first the Pentateuch by around 400 BC, then the Prophets during the Hasmonean dynasty (140-116 BC), and finally the remaining books.
The first five books – Genesis, Exodus, Leviticus, Numbers and Deuteronomy – reached their present form in the Persian period (538–332 BC)
The books of Joshua, Judges, Samuel and Kings follow, forming a history of Israel from the Conquest of Canaan to the Siege of Jerusalem 587 BC.
The two Books of Chronicles cover much the same material as the Pentateuch and Deuteronomy history dates from the 4th century BC.
Chronicles, Ezra–Nehemiah, were finished during the 3rd century BC.
Catholic and Orthodox Old Testaments contain two (Catholic Old Testament) to four (Orthodox) Books of Maccabees, written in the 2nd and 1st centuries BC.
Of the remainder, the books of the various prophets – Isaiah, Jeremiah, Ezekiel, Daniel and the twelve "minor prophets" – were written between the 8th and 6th centuries BC, with the exceptions of Jonah and Daniel, which were written much later.
The "wisdom" books – Job, Proverbs, Ecclesiastes, Psalms, Song of Solomon – have various dates: Proverbs was completed by the Hellenistic time (332-198 BC), though containing much older material as well; Job completed by the 6th Century BC; Ecclesiastes by the 3rd Century BC.