This question already has an answer here:

I wrote the following sentence in an article:

Only in June it created repositories.

The editor corrected me:

Only in June did it create repositories.

What's the explanation for "did" in this case? It doesn't sound like emphasis, because the following word is not a verb.

marked as duplicate by Peter Shor , Edwin Ashworth, tchrist, Drew, A E Jan 8 '15 at 10:59

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 3
    If you begin a sentence with a negative adverbial clause, as per your example, the word order is inverted and the auxiliary that you would use for an interrogative is inserted. – Martin Jan 7 '15 at 21:54
  • 2
    You began your sentence with only. That necessitates the use of the did. But you seem to understand this. What, then, is your question? – anongoodnurse Jan 7 '15 at 22:29
  • 1
    No, in fact I didn't know that. I found the explanation at english.stackexchange.com/questions/62208/… because of Martin's comment. – rodrigorgs Jan 7 '15 at 22:43
  • @rordigorgs No! because yours isn't a case of voluntary inversion as per the answers listed. It's mandatory - you have to do it in this situation. – Araucaria Jan 8 '15 at 0:15
  • 1
    @tchrist Yes, possible to use an only with a completely different meaning there. Maybe that's what rodrigorgs wanted to say. – Araucaria Jan 8 '15 at 2:12
  1. Only in June was it creating repositories.

  2. Only in June it was creating repositories. (ungrammatical)

In example (1) we see the auxiliary and subject change places. In example (2), the auxiliary and subject are the same as they would be in a normal sentence. It is ungrammatical.

  1. Only in June did it create repositories.

  2. Only in June it created repositories. (ungrammatical)

In sentence (3), again, we see subject auxiliary inversion. Sentence (4) has no auxiliary - this is because it has no inversion. However, it is ungrammatical.

Although we can insert auxiliaries for emphasis, the use of do is obligatory in the sentences above. It is not about emphasis. It is because we need to invert the subject and auxiliary verb. They have to change places. We can't do this if there is no auxiliary, so in sentence (3) we use the 'dummy' auxiliary DO so that we can create an inversion. Note that the main verb create can't be used for inversion:

  • Only in June created it repositories. (ungrammatical)

Moving only to the front of a sentence will trigger subject auxiliary inversion in main clauses under certain conditions. Here are some examples:

  • Only if we've received the papers can we release the prisoner.
  • *Only if we've received the papers we can release the prisoner. (wrong)
  • Only after the concert did I notice Pavarotti in the back row.
  • *Only after the concert I saw Pavarotti in the back row. (wrong)
  • Only in extreme circumstances did they steal.
  • *Only in extreme circumstances they stole. (wrong)
  • Only in the houses of parliament will you find this many cads.
  • *Only in the houses of parliament you will find this many cads. (wrong)

The grammatical sentences have certain features in common:

  • i) These sentences all have subordinate preposition phrases which occur before the main clause (phrases with if, before, after, during and so forth)
  • ii) These prepositions are always prepositions of time, place or condition.
  • iii) The head preposition in each case is being modified by only.
  • iv) Only must have the sense of not except in such examples.

When these conditions apply, subject auxiliary inversion will apply. Notice that although only modifies the subordinate phrase, the inversion occurs in the main clause. The subject auxiliary inversion does not occur in the subordinate clauses.

The Original Poster's Question

The main clause in the Original Poster question is a version of the canonical (normal) clause:

  • it created repositories.

However, this main clause is fronted by a temporal preposition phrase in June. This preposition phrase in June is being modified by the adverb only. This requires us to invert the subject and the auxiliary verb in the main clause. As we previously noted, the main clause is:

  • it created repositories.

There is no auxiliary in this clause - so we need to use the dummy auxiliary, do for the inversion:

  • did it create repositories.

This gives us the sentence:

  • Only in June did it create repositories.

Hope this is helpful!

  • 1
    And we can't just invert "it created" to "Only in June created it repositories" because in present-day English we generally don't invert verbs that aren't auxiliaries, so did has to be press-ganged in to do the job. – Jon Hanna Jan 8 '15 at 1:06
  • @JonHanna Thanks, is that better? - or worse? – Araucaria Jan 8 '15 at 1:21
  • 2
    I think so. I myself had started to write something that turned into such a convoluted mess that I deleted it to start again and found that you'd given this answer in the meantime covering everything I had intended to bar that point. – Jon Hanna Jan 8 '15 at 1:27
  • You've had me delete two or three over the last couple of days ;) But often glad you got there first - cuz I hadn't thought of most of the fiddly bits. – Araucaria Jan 8 '15 at 1:30
  • 2
    Yes, and it can be hard to decide just how fiddly to get, combined with the relative haste of answers compared to other types of writing often leading to Pascal's apology; "I made this very long, because I did not have the leisure to make it shorter". – Jon Hanna Jan 8 '15 at 1:34

Not the answer you're looking for? Browse other questions tagged or ask your own question.