One of the great struggles we have with the God revealed in Scripture has to do with texts that say, “God never changes,” and other texts that seem to say things like, “God changed his mind,” or “God regretted.”
Malachi 3:6—“For I the LORD do not change; therefore you, O children of Jacob, are not consumed.”
Genesis 6:7—“So the LORD said, ‘I will blot out man whom I have created from the face of the land, man and animals and creeping things and birds of the heavens, for I am sorry that I have made them.’”
1 Samuel 15:11, 1 Samuel 15.35″>35—“I regret that I have made Saul king, for he has turned back from following me and has not performed my commandments. … And Samuel did not see Saul again until the day of his death, but Samuel grieved over Saul. And the Lord regretted that he had made Saul king over Israel.”
Two important questions.
First, how can a God who says he never changes turn around and change his mind or actions (or both) toward someone?
And second, why does God do some things (like create the human race, or choose Saul to be the King) if he knows that they will fail?
These are two really big questions (perhaps too big for a blog-post, but we have to start somewhere)!
First Question: A changeless God who changes his mind?
The short answer to the first question is that God does (insofar as people understand it and experience it) seem to change his mind on some things, but that is only because God never changes his mind on others. In order to think about this more, consider this reflection in Kaiser, Davids, Bruce and Brauch’s excellent book Hard Sayings of the Bible:
[This] text (1 Sam. 15) affirms that God changed his actions toward Saul in order to remain true to his own character or essence. Repentance in God is not, as it is in us, an evidence of indecisiveness. It is rather a change in his method of responding to another person based on some change in the other individual. The change, then, was in Saul. The problem was with Saul’s partial obedience, his wayward heart and covetousness.
To assert that God is unchanging does not mean he cannot experience regret, grief and repentance. If unchangeableness meant transcendent detachment from people and events, God would pay an awful price for immutability. Instead, God enters into a relationship with mortal beings that demonstrates his willingness to respond to each person’s action within the ethical sphere of their obedience to his will. 
The point here is that God’s essential nature and his ultimate commitment to his own sovereign will do not change.
When God engages in relationship and interaction with a volitional person (such as King Saul) or a people (such as Israel), he remains true to his own “God-ness” and his ultimate purposes. In cases where the person or people with whom God is partnering decide they don’t want to do things along the lines of God’s will, God remains true to himself, which will mean that they will feel and experience every indication that they and God are not on the same page.