Abdul-Rahman bin Samura reported,

The Prophet ﷺ said, "Abdul-Rahman bin Samura, do not ask for a position of authority. For if you are granted it after asking, you will be left to handle it on your own, but if you are granted it without asking, you will be helped in carrying it out. And when you swear an oath and then see that something else is better, expiate for your oath and do what is better."

Bukhari 6622

Sahih

حدثنا أبو النعمان محمد بن الفضل حدثنا جرير بن حازم حدثنا الحسن حدثنا

عبد الرحمن بن سمرة قال

قال النبي ﷺ يا عبد الرحمن بن سمرة لا تسأل الإمارة فإنك إن أوتيتها عن مسألة وكلت إليها وإن أوتيتها من غير مسألة أعنت عليها وإذا حلفت على يمين فرأيت غيرها خيرا منها فكفر عن يمينك وأت الذي هو خير

البخاري 6622صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Oaths and vows
Chapter
Allah's saying, "Allah will not impose blame upon you for what is meaningless in your oaths, but He will impose blame upon you for oaths you have made binding. So its expiation is the feeding of ten needy people from the Awsat of what you feed your own families or clothing them or the freeing of a Raqaba. But whoever cannot find the means, then a fast of three days. That is the expiation for oaths when you have sworn. And guard your oaths. Thus does Allah make clear to you His verses that you may be grateful."
Numbering
Darussalam 6622
Bukhari 6622