Dr. `Ugail Jasim An-Nashmi, professor of Shari`ah at the University of Kuwait, states the following: One of the conditions of Hajj tamattu` is that the pilgrim remains in Makkah (after performing `Umrah) until the eighth of Dhul-Hijjah when he is to put on ihram for Hajj. If, during this period, he went out to Madinah or back home, jurists differ as to whether this nullifies the tamattu` or not. The point involves details of how distant the pilgrim went out, as follows:

According to the Hanafi School, if the pilgrim had brought the sacrificial animal with him to Makkah and then performed `Umrah and went back home (and then came back to Makkah to resume the rituals of tamattu`), his tamattu` would be valid, as his ihram for tamattu` was still in effect. But if he did not bring the sacrificial animal with him, his tamattu` would be invalidated by going back home, as this would be an end of the journey on which he went out from the outset.

It might happen that the pilgrim goes back home before completing Tawaf (circumambulating the Ka`bah) and then comes back to Makkah, [completes Tawaf] and performs Hajj. In such a case, the Hanafi scholars believe that his tamattu` would be invalidated if the rounds of Tawaf before going back home were more than those performed after coming back to Makkah. If the rounds after coming back to Makkah were more, his tamattu` would remain valid.

The Shafi`i School regards it a condition that the pilgrim does not go back to the miqat in order to assume ihram for Hajj. If he did, his tamattu` would be invalidated, but there would be no expiation (sacrificing an animal) required from him in this case.

The Hanbali School stipulates that the pilgrim does not go between the `Umrah and Hajj on a long journey in which the prescribed Prayers may be shortened.

The Maliki School holds that the pilgrim ought not to go back to his country or go a similar distance between the `Umrah and Hajj. If he did, his tamattu` would be invalidated. But if he went a distance less than that to his country and then performed Hajj during the same year, his tamattu` would be valid.

Based on the above, it is concluded from the opinion of the majority of scholars that if a pilgrim, in the first place, intended tamattu` and then performed `Umrah and went to Madinah while he is not a resident of Madinah, his tamattu` would be invalidated.

But in the opinion of the Maliki school, his tamattu` would be valid, as he did not go back to his country or to a distance similar to it.

The difference among scholars over this point is owing to the fact that there is no religious text that mentions it; hence, they have resorted to their personal opinions on the matter.

`Umar ibn Al-Khattab was reported to have said in this respect, “If a pilgrim (intending tamattu`) performed `Umrah in the months of Hajj and resided in Makkah [till the exact days of Hajj in which he would put on ihram for Hajj], his tamattu` would be valid; but if he went out (of Makkah) and came back thereto, his tamattu` would be invalidated.”

In my opinion, the Maliki view seems to be moderate and more reasonable as the said pilgrim, though he went outside Makkah, is still in a state of traveling (having not returned to his country or gone a similar distance), and thus his going back to Makkah to accomplish the rituals of tamattu` is valid.

Allah Almighty knows best.