Srimad Bhagavatam Canto 10, Chapter 36, Text 38

SB 10.36.38

sri-akrura uvaca
rajan manisitam sadhryak
 tava svavadya-marjanam
siddhy-asiddhyoh samam kuryad
 daivam hi phala-sadhanam
 
Translation: 
 
Sri Akrura said: O King, you have expertly devised a process to free yourself of misfortune. Still, one should be equal in success and failure, since it is certainly destiny that produces the results of one’s work.
Srimad Bhagavatam Canto 10, Chapter 36, Text 37
Srimad Bhagavatam Canto 10, Chapter 36, Text 39