David was told that the Philistines were attacking and looting the city of Keilah. He asked God if he and his six hundred men should attack the Philistines and defend Keilah. God told him, “Yes.” The six hundred men, however, lacked confidence. Again, David asked God; and he received assurance that God would deliver the Philistines into their hands.
God enabled David’s men to overcome the Philistines; however, Saul learned that David and his men had defended Keilah and were now in the gated city of Keilah. Saul considered this as good news because he envisioned David and his men trapped within the gated city.
Seems that there were no secrets, because David learned that Saul was plotting to attack Keilah. David asked God, “Will the citizens of Keilah surrender me and my men to Saul?” “They will,” God replied. With that, David and his men left Keilah. [Reflection based on the Bible Reference – 1 Samuel 23:1-13]