It's your life you are writing about. Don't cheap out, buy a gun for the job at hand.
Will 9mm work?
Yest it will.
I know a guy who temple shot a deer in his garden and dropped it like a hot potato.
Is it advisable, he'll no, but it did kill the deer.
That's like the story of the guy killing a grizzly with a 9mm pistol, he got lucky.
I worked with a guy who use to be a gang banger until he got shot nine times with a 9mm pistol and lived. That ended his gang banger days.
Buy what you want, but personally I bought a Glock 20 in 10mm for woods carry.
It is only money, you can scrape it up over time.