As you read through the book of Psalms, you'll notice that in many of them, David addresses God as "my God." However, today's verse is different. In verses 1-7, David pleads for mercy and cleansing, as he admits that he has sinned against God.
"Have mercy on me, O God,
according to your steadfast love;
according to your abundant mercy
blot out my transgressions.
Wash me thoroughly from my iniquity,
and cleanse me from my sin!
For I know my transgressions,
and my sin is ever before me.
Against you, you only, have I sinned
and done what is evil in your sight,
so that you may be justified in your words
and blameless in your judgment.
Behold, I was brought forth in iniquity,
and in sin did my mother conceive me.
Behold, you delight in truth in the inward being,
and you teach me wisdom in the secret heart.
Purge me with hyssop, and I shall be clean;
wash me, and I shall be whiter than snow."
-Psalm 51:1-7
Notice in these verses that David's approach to confessing his sins is to take God's attitude toward sin. Just as God sees them, David also sees his sins as transgressions, iniquity, and evil. He sees them as a result of a life of offensive nature. He prays, "O God." David knew God well enough to know God's character as gracious, loving, and merciful; it's with this knowledge that he prays to God to show His unfailing love and mercy through blotting out his transgressions.
This phrase "blot out my transgressions" is important to understand within the context of the time it was written. The word "transgressions" indicated a revolt against God. And it was through David violating God's commandments (adultery with Bathsheba and the murder of her husband, Uriah). David had revolted against God, and that it was only by God's grace, mercy, and unfailing love that could erase his sin. In the time that this Psalm was written, when debts or crimes were forgiven, they would be blotted out (or erased) from the books in which they were written. So this language of David asking God to blot out his transgressions is asking God to erase his sin.
We also see this same language being used in the New Testament. In Acts 3:19, Peter urges a crowd that had gathered to repent so "that your sins may be blotted out."