Probably going to get down voted to oblivion… But here it goes
I recently asked my boss for a raise to help off set high inflation. Boss said no, they couldn't give me a raise. I then started looking and found a job who would pay me what I was asking. I went back to my boss told him I found a new position and gave my 2 week notice.
Then my boss told me “Congratulations I'm excited for you and your family, thank you for all you have done for the team, and you will be missed.”. He asked what it would take for me to say, he said he couldn't match it. We also scheduled a team lunch, which he paid for out of pocket.
I write this because this is normal behavior, this is what companies should do and what employees should expect. Honestly, if you work somewhere and you don't think this would happen, you should start looking for another job.
I don't say this for just your well-being either. By staying at a company that treats you badly, you are propping up bad companies. It costs nothing to treat people like human beings, kindness doesn't effect the bottom line. But, losing employees does. Bad companies should fail, bad management should fail. If companies cannot keep employees they either change or face constructive destruction.