My understanding is that God knows every minute detail of the past, present and future. And yet several times throughout the Old Testament, God issues a command to his people or an individual and we find out the people/person failed to follow the command. For example, why would God instruct the Israelites to utterly destroy the Caananites knowing they wouldn't do it? God also gives instructions to the various Kings of Israel/Judah, again knowing full well that the Kings wouldn't follow the command. I'm hoping to get some clarity on this point, or an "aha" moment as this has been bothering me while reading the Old Testament. Thanks
There is no necessity in God. He is the first cause. All He does is a voluntary initiative. Part of asking "why" questions is to find preceding cause/effect chains that led up to an event occurring. There is no "Why" here. God is. His speech is an expression of His unchanging nature.
21 “His eyes are on the ways of mortals; he sees their every step. 22 There is no deep shadow, no utter darkness, where evildoers can hide. 23 God has no need to examine people further, that they should come before him for judgment. 24 Without inquiry he shatters the mighty and sets up others in their place. 25 Because he takes note of their deeds, he overthrows them in the night and they are crushed. (Job 34)
The people He commands are not His only audience.
- All He does is viewed by the angels.
- Later believers are instructed by God's commands.
- The unbelieving world will be judged according to God's commands.
God is performing an experiment for our benefit, showing us what does not work when it comes to repairing the world. In this case, a theocratic state given perfect laws and granted the privilege and on occasion miraculous assistance by God to kill wicked people cannot cleanse the world. Previous experiments involved proving that a perfect environment (Eden) cannot prevent evil, killing all wicked people on earth (Noah's flood) could not eradicate evil, etc. He is working up to unmerited grace and the cross.
God did issue the command for a reason, so it must have achieved its intended effect, because:
As the rain and the snow come down from heaven, and do not return to it without watering the earth and making it bud and flourish, so that it yields seed for the sower and bread for the eater, 11 so is my word that goes out from my mouth: It will not return to me empty, but will accomplish what I desire and achieve the purpose for which I sent it. (Isaiah 55)
We know from Jonah that God is merciful. Sometimes He issues a warning and people repent, so repentance is the goal and not destruction. In the Canaanite's case this seems unlikely.
Ultimately, God wants to show people that only He can save them from evil.
The Lord looked and was displeased that there was no justice. 16 He saw that there was no one, he was appalled that there was no one to intervene; so his own arm achieved salvation for him, and his own righteousness sustained him. 17 He put on righteousness as his breastplate, and the helmet of salvation on his head;
he put on the garments of vengeance and wrapped himself in zeal as in a cloak. 18 According to what they have done, so will he repay wrath to his enemies and retribution to his foes; he will repay the islands their due. 19 From the west, people will fear the name of the Lord, and from the rising of the sun, they will revere his glory. For he will come like a pent-up flood that the breath of the Lord drives along. (Isaiah 59)
God has self-control (Isaiah 42:14), so that he can choose to what extent he will exercise his power and knowledge. Although God is all-powerful, that does not mean that he unleashes his limitless power any time he executes judgment on people. His power is tempered by his mercy and wisdom. In a similar way, although God is all-knowing, it does not mean that God uses his knowledge to predict everything that will happen. He chooses not to foreknow some things so that we can make our own decisions and express genuine love and obedience.
For example, when God commanded Abraham to sacrifice his son Isaac, and Abraham obeyed and was about to kill his son on the altar he had built, God stopped Abraham and said by means of his angelic messenger:
“Do not harm the boy, and do not do anything at all to him, for now I do know that you are God-fearing because you have not withheld your son, your only one, from me.”
— Genesis 22:12 (NWT)
We can see that God had waited for Abraham to decide to obey him. God chose not to foreknow whether Abraham would obey.
The belief that God uses his omniscience to fully know the future is called Predestination. It is not taught by the Bible. The Bible clearly teaches that nothing can be hidden from God. His knowledge of the past and present are complete, so that his judgements and decisions are perfect. However, when it comes to knowledge of the future, God is selective in what he chooses to foreknow so that he does not overstep our free will.