The Bhagwad Gita chapter 2, verse 47 states:
karmaṇy-evādhikāras te mā phaleṣhu kadāchana
mā karma-phala-hetur bhūr mā te saṅgo ’stvakarmaṇi
I am confused, how should one work, then how will I know if I have to do something if not for the results?
I will study because I want results or get better education in the long term; I will switch job if I want to be better paid; I will ask a girl out, if I want to have some form of relation with her; If I am leading an army, I will do some tactic to achieve something, which will later result in something bigger. If not for the result I will not do any work, which leads to