Some translations set each line of poetry farther to the right than the rest of the text to make it easier to read. The ULB does this with the poetry in 12:1-7 and 12:13-14.
This chapter gives a series of disconnected pieces of advice. Translators should not try to smooth the transitions between these pieces of advice. The advice in these statements do not apply in every situation. Therefore, they should be seen as "good ideas."
At the end of a very impressive life, Solomon looks back and sees that the only real lasting thing in this world is Yahweh. The purpose of his life was to honor Yahweh, something he should have done far more throughout his life. Therefore, he felt that his life was wasted. (See: [[rc://en/ta/man/jit/figs-explicit]])