Here David's heart is spoken of as if it were a container, and what he desired is spoken of as if it were an item in the container. Alternate translation: "you desired ... to desire to do that" (See: [[rc://en/ta/man/jit/figs-metaphor]])
Possible meanings are 1) Yahweh's name represents himself. Alternate translation: "for me" or 2) Yahweh's name represents his reputation. Alternate translation: "for my reputation" (See: [[rc://en/ta/man/jit/figs-metonymy]])