Does God repent? If not, then why does the KJV display God responding by way of repenting? If so, does God make mistakes? Does not God know all things?
Just a couple of questions I would like to discuss and possibly provide some clarity to.
The KJV records God "repenting" over 20 times. Although, I think we sometimes forget the words used in the Bible are not originally English words, they are Hebrew or Greek, and that context is always key. In this case they are Hebrew, because God repenting is all within the Old Testament.
There are two Hebrew terms being used for repent. "Repent (ed, est, eth, ing)" in Hebrew is...
nacham, which means: properly, to sigh, i.e. breathe strongly; by implication, to be sorry, i.e. (in a favorable sense) to pity, console or (reflexively) rue [regret]; or (unfavorably) to avenge (oneself)—comfort (self), ease (one's self)
shuwb, which means: to turn back (hence, away) transitively or intransitively, literally or figuratively (not necessarily with the idea of return to the starting point); generally to retreat; often adverbial, again
"Repentings" in Hebrew is nichuwm (from nacham), which means: properly, consoled; abstractly, solace. "Repentance" in Hebrew is nocham (from nacham), which means: ruefulness.
"And God saw that the wickedness of man was great in the earth, and that every imagination of the thoughts of his heart was only evil continually. And it repented the LORD that he had made man on the earth, and it grieved him at his heart. And the LORD said, I will destroy man whom I have created from the face of the earth; both man, and beast, and the creeping thing, and the fowls of the air; for it repenteth me that I have made them." (Gen. 6:5-7, KJV)
The Hebrew term used for "repented" and "repenteth" in this passage is nacham. So does God make mistakes? No. This verse (and every other verse that uses nacham or its cognates in reference to God) is indicating God expressing an emotion, not making a mistake. The NASB Life Application Study Bible comments on this passage with this,
"The people's sin grieved God. He was expressing sorrow for what the people had done to themselves, as a parent might express sorrow over a rebellious child."
Just like our sin grieves the Holy Spirit within us (Eph. 4:30), God was repented (sighing/sorry—nacham) and grieved in His heart with the sins of His creation back then as well.
(Note: The NKJV, NASB, & CEV say "sorry" in place of "repented", and the AMP says "regretted". They all say "grieved".)
The "grieved" used in context in Gen. 6:5-7 in Hebrew is atsab, which means: to worry, pain or anger—displease, grieve, hurt, make/be sorry, vex. Again, with the context of this word being used you'll see God is expressing an emotion in this passage, not displaying a mistake.
"Repent (ed, est, eth, ing, ings, ance)" is used a total of 45 times in the Old Testament. The Hebrew term nacham is used 40 times and shuwb is used only 3 times. Repentance (nocham) and repentings (nichuwm) are only used once. I should note also that all 45 do not belong to God repenting. And where they do belong to God they are repeatedly indicating God expressing an emotion (nacham) and His response (shuwb), not Him making a mistake.
With what we now know, looking at the "repent" that God does from the context of the appropriate Hebrew definition/term, we see He is not turning away from what He planned (Job 23:13) or surprised like He didn't know this was going to happen. He is simply displaying an emotional expression from the things He sees going on with what He created (e.g. like His grace and mercy exhibited in other passages, some even in response with His emotion). The same was done by Jesus.
"And when He had looked around at them with anger, being grieved by the hardness of their hearts, He said to the man, “Stretch out your hand.” And he stretched it out, and his hand was restored as whole as the other." (Mk. 3:5, NKJV).
Does God Really Know All Things?
How can God be Creator and not know everything in advance involving what He created? How can God be the first and the last, the beginning and the end, eternal, and not know everything beforehand? He can't.
"The LORD looks from heaven; He sees all the sons of men. From the place of His dwelling He looks on all the inhabitants of the earth; He fashions (yatsar- to mould into a form; especially as a potter; figuratively, to determine) their hearts individually; He considers (biyn- to separate mentally (or distinguish), i.e. (generally) understand) all their works." (Ps. 33:13-15, NKJV)
"For the eyes of the LORD run to and fro throughout the whole earth, to show Himself strong on behalf of those whose heart is loyal to Him. In this you have done foolishly;
therefore from now on you shall have wars." (2Chr. 16:9, NKJV)
"Where can I go from Your Spirit? Or where can I flee from Your presence? If I ascend into heaven, You are there; if I make my bed in hell, behold, You are there." (Ps. 139:7-8, NKJV)
"…His understanding is unsearchable." (Isa. 40: 28, NKJV)
"And there is no creature hidden from His sight, but all things are naked and open to the eyes of Him to whom we must give account." (Heb. 4:13, NKJV)
“I am the Alpha and the Omega, the Beginning and the End,” says the Lord, “who is and who was and who is to come, the Almighty.” (Rev. 1:8, NKJV)
So, let's insert a cause and effect here.
God is eternal (Deut. 33:27, Ps. 90:2, Isa. 57:15, Jer. 10:10).
He sits in eternity, we sit in the temporal.
He sees everything as one scene, not like our moment by moment vision.
The Bible tells us God is not the author of confusion (akatastasia—instability, i.e. disorder– commotion, confusion, tumult) but of peace, decency and order, righteous, and perfect in all His ways (1Cor. 14:33, 40, Deut. 32:4, Ps. 11:7; 18:30; 19:7-9).
Therefore, before God created anything, He would have to have a plan for it first. Thus, the lifetime of all He created has its specific lot in what He planned before He created it.
From what has been seen and explained, it is clear that the verses or passages where He's showing/displaying emotions (whatever that may be, in this case repenting) is simply Him showing Himself as a God with emotions, just as Jesus displayed (Jn. 11:32-38, Lk. 19:37-41ff), and not because He made a mistake.
(i)the verses displayed above (and there are many more than they),
(ii)the abundant prophecies and promises given by the mouth of God Himself (which means He must know the ending from the beginning in order to tell what's going to happen beforehand [cf. Isa. 44:6-8; 46:9-11; 48:3-5]), and
(iii)the content of scripture references like these (Ps. 139:1-16, Prov. 5:21; 15:3, Jer. 17:10),
..it is indisputably clear that God knows all things in advance.