When Solomon was desirous of conveying the Ark into the Temple, the
doors shut themselves of their own accord against him. He recited
twenty-four psalms, yet they opened not. In vain he cried, "Lift up your
heads, O ye gates" (Ps. xxiv. 9). But when he prayed, "O Lord God, turn
not Thy face away from Thine anointed; remember the mercies of David,
Thy servant" (2 Chron. vi. 42), then the gates flew open at once. Then
the enemies of David turned black in the face, for all knew by this that
God had pardoned David's transgression with Bathseheba.
THE TALMUD, _Moed Katon_, fol. 9, col. 1.