Question: Hello Bob, Would you explain what Zechariah 12:7 is referring to?
Response: First, this verse (and chapter 12:1-10 in toto) is dealing with the events which will occur prior to and in the process of the Second Advent (specifically, the battle of Armageddon). Coincident with the "reports" (of the Second Advent: Dan.11:44; cf. Rev.16:14) which will prompt antichrist to assemble the armies of the world in the land of Israel to do battle with our returning Lord, there will be a general revolt within Israel against the beast and his control. Jerusalem and its people (after suffering intensely: cf. Zech.14:2) will be delivered by our Lord's personal intervention (Zech.14:4), but prior to this event Christ will "go and fight with those nations" who are attacking Judah (Zech.14:3; that is, the areas of the south which are not part of urban Jerusalem: = "tents"; cf. M. Unger's Commentary on the Old Testament v.2, in. loc.). In this way, deliverance comes to "Judah" (i.e., not the city of Jerusalem proper) first, for that is where the main battle had been raging (cf. Zech.12:6).
But I suspect that a big part of your question is really about the odd-sounding phraseology "so that the honor of the house of David and of Jerusalem's inhabitants may not be greater than that of Judah" (NIV, KJV, and NASB all have a similar rendition). We should not imagine that the main idea here is that God's purpose is to avoid giving Jerusalem et al. greater honor than Judah (which would indeed seem strange), although this is the obvious conclusion which such translations proffer. The problem is that in Biblical Hebrew, there is really no such thing as a completely distinct "result clause", that is, no way to say (so that modern English speakers/translators can see it clearly) "so that ... [something] will/did actually happen". But as many contemporary students of BH have begun to see (cf. especially J. Wash Watts, A Survey of Syntax in the Hebrew Old Testament, pp.129-130; pace BDB's lexicon, in loco lema'an - the introductory conjunction here), purpose constructions in Hebrew often "work better" if seen as essentially result constructions instead (i.e., sometimes they actually are equivalent result constructions). Applying this principle here, we are justified in re-translating this portion of Zechariah 12:7 "so that [or, "with the result that"] the honor of the house of David and of Jerusalem's inhabitants will not be greater than that of Judah". That is to say, this verse is a description of the way things will actually turn out because of the sequence of events, and not a statement of preference by God to deliberately put the rest of Judah in front of Jerusalem et. al. After all, the Messiah will reign in Jerusalem, and what greater honor can there be than that?
Please see the following link for all of the details of the battle of Armageddon and the events preceding it:
The 2nd Advent and Armageddon: The Return of Christ (CT 5)
Hope this helps.
Yours in Christ,