There seems to be a contradiction in the ideas of attachment and attainment. As Buddhism teaches non-attachment it also teaches practitioners to work toward freeing all sentient beings from delusions. How can anybody work toward such a lofty goal without being attached to the goal?
It is impossible not to set goals. When we have to go to the bathroom, we set a goal of getting our bodies to a toilet before we soil ourselves. Attachment causes excessive suffering in the event we soil ourselves. Soiling ourselves now and again is a part of our practice of getting to bathrooms.
If you are suffering in some way, it is likely that the suffering has its roots in your attachment to an idea. In working on non-attachment, you do not have to let go of your goals. Your goals are part of your practice. Your suffering is also part of your practice. Just because you understand that attachment causes suffering does not mean you can cut off all attachment, it just gives you an idea of where to look when you suffer.
When you want to attain something, that attainment will come with attachment and suffering. If you don’t want to attain anything, that non-attainment will come with attachment and suffering. Attain away.