חֲצֽוֹת־לַ֗יְלָה אָ֭קוּם לְהוֹד֣וֹת לָ֑ךְ עַ֝֗ל מִשְׁפְּטֵ֥י צִדְקֶֽךָ׃
Pada tengah malam aku bangun untuk bersyukur kepada-Mu atas hukum-hukum-Mu yang adil.
Rashi
I shall awaken the dawn It is the custom of other kings that the dawn awakens them, but I awaken the dawn, for I rise at midnight, when the psaltery and the harp awaken me, as our Rabbis said (Ber. 3b): A harp was suspended above David’s bed. As soon as midnight arrived, the north wind would blow on it and it would play by itself.
Siftei Chakhamim
For חצות is not the noun. I.e., [Rashi is telling us that the term] חצות here is not a noun like it is in (Tehillim 119:62), “ חצות לילה (In the middle of the night) I will rise to praise You.” Here this is not so, because it is preceded by a כ , which is not appropriate for a noun. Furthermore, כחצות implies uncertainty as to when midnight is, and surely, Hashem has no such doubt! Thus כחצות must mean, “When the night is divided.”
Rabbeinu Bahya
According to Shemot Rabbah 18,2 the meaning of the word כחצות is that midnight would have a dual function; death as a form of retribution for the Egyptians, and justice and righteousness for the long suffering Israelites.
Rashi
watches Half the night, two watches, and according to one who says that the night consists of three watches, David would rise from bed at the first third of the night and engage in Torah until midnight, as it is said: “to speak of Your word.” From midnight on, he would engage in songs and praises, as it is said (verse 62): “At midnight, I rise to give thanks to You.”