The Prophet (sws) is reported to have said:
A woman whose three children die will be shielded by them from Hell. On that a woman asked: If only two die? He replied: Even two (will shield her from Hell). (Bukhārī, Kitāb al-Janā’iz)
Is this a valid Hadīth ?
This Hadīth is absolutely valid and should be understood while keeping into consideration the following two premises:
1. According to the Qur’ān, Paradise is actually a reward of one's patience and perseverance:
And because they were patient and constant, He (-- Allah--) will reward them with a paradise great and garments of silk. (76:12)
During the course of a person’s life there are come a number of instances when the Almighty tests one's patience so that if a person is successful in this test he may be rewarded.
2. It is taken for granted in all such Ahādīth that the person in question is a practising Muslim who fears Allah.
Keeping these premises in view, the Hadīth you have referred to can easily be understood. Death of a young one, it is obvious, is an instance which really tests the perseverance of a Muslim and his or her faith and trust in the Almighty. If a person adopts an attitude of patience by submitting to the will of Allah even after such a tragedy, and keeps doing righteous deeds then he or she can hope to end up in Paradise and be shielded from the Fire of Hell as the Hadīth says.