According to tradition, Joachim went to a temple to pray, but was not allowed in because he did not have a child. Anna heard, prayed, and sacrificed. She promised God that she would bring up a child in God's name. An angel came to Anna and Joachim and told them that God would grant her a baby. Anna had the baby soon after and named the girl Mary. Anna kept her promise. When Mary was about three years old Joachim and Anna brought her up in the Second Temple.