Was the First Apocalypse of James written after the Second Apocalypse of James? The current version of the Wikipedia article for the First Apocalypse of James has the following sentence at the end of the article:


  One of the most curious features of the First Apocalypse of James is that the range of dating of its original text, assigned to it by scholars, requires that it was written after the Second Apocalypse of James.


Unfortunately, there is no citation for this.

Was the First Apocalypse of James written after the Second Apocalypse of James? If so, on what criteria is this based? And why are the names so confusingly ordered?
The terms &quot;first&quot; and &quot;second&quot; in these two titles are &quot;scholarly conventions to distinguish the two,&quot;1 not meant to indicate the date of origin.  Instead, they reflect their original ordering in Codex V of the Nag Hammadi documents, in which the First Apocalypse precedes the Second Apocalypse.  Still, this ordering was no accident:

The presence and order of the two James apocalypses in Codex V are undoubtedly due to deliberate scribal organization.  The two apocalypses stress different aspects of the James tradition and actually complement one another.  The setting of 1 Apoc. Jas. emphasizes the period prior to the suffering of James, while 2 Apoc. Jas. describes his suffering and death in line with the predictions in 1 Apoc. Jas.2

Next we can turn to the dating of the works.  There is little certainty about the dating, but the Second Apocalypse is generally dated before the First Apocalypse based on comparisons of the texts to those of other early movements.  Thus Robinson writes, regarding the Second:

The absence of allusions to the later developed gnostic systems, and the almost total absence of allusions to the New Testament tradition suggest an early date for the origin of the tractate.2

Primarily on this basis, numerous scholars date the text to the early or middle second century.3 4
On the other hand, the final text of the First Apocalypse reveals some similarities to Valentinian writings:

The Valentinian theologoumena utilised in it (cf. especially the doctrines of an upper and a lower Sophia, or of 'Sophia' proper and Achamoth', which also occur in the text outside the mystery formulae quoted: p. 36.5, 8) seem to presuppose the fully-developed Valentinian system, and therefore suggest the composition of the document at the earliest towards the end of the 2nd century.5

Similarly, &quot;the rejection of a bodily fraternal relationship between Jesus and James (p.24.15f.)&quot;5 points to a later date.
Summary
The names of these two works are based on the order in which the appear in the codex in which they were originally found.  This seems to have been the deliberate ordering of a scribe based on their contents, not the presumed date of origin.
Textual analysis points to an earlier date for the Second Apocalypse due to its lack of allusion to early Gnostic texts, as compared to the use of developed Valentinian thought in the First Apocalypse.  Thus the Second Apocalypse is dated to early or middle second century, while the First Apocalypse is dated to the late second century at the earliest.

References:

Mercer Dictionary of the Bible, 427

Robinson, Nag Hammadi Library in English, 270

Myllykoski, &quot;James the Just in History and Tradition,&quot; part II, Currents in Biblical Research 6.1 (2007), 54

Funk, in Schneemelcher, New Testament Apocrypha, 328

Funk, in Schneemelcher, New Testament Apocrypha, 315