Can someone help me out, I, for the life of me, can't figure out the attack rolls

Say. Look at the Moradin Priest for example, he has a Strength of +2, but he has a +4 to hit on his warhammer, where are the other +2 coming from? Training? If you have training in that weapon do you automatically get a +2?