I taught in a small teacher's college for three or four years at which point all the administrators got a pay raise and the teaching faculty didn't.
The function of prayer is not to influence God but rather to change the nature of the one who prays.