"And the day of death than the day of one's birth" (Ecclesiastes 7:1, continued) — the day of a person's death is better than the day on which he was born. Why? On the day on which he is born, no one knows whether his deeds will be worthy or not; but when he dies, he makes his deeds known to humankind.
Why the Day of Death Surpasses the Day of Birth in Tanchuma
Midrash Tanchuma Buber, Vayakhel 1:2
ויום המות מיום הולדו (קהלת שם), יום מיתתו של אדם, מיום שנולד בו, למה ביום שנולד בו אין אדם יודע אם מעשיו יפים אם לאו אבל כשהוא מת הוא מודיע מעשיו לבריות.