kjv@1Samuel:15:20@ And Saul said unto Samuel, Yea, I have obeyed the voice of the LORD, and have gone the way which the LORD sent me, and have brought Agag the king of Amalek, and have utterly destroyed the Amalekites.
Doing what is right is not simply performing the action, it is also in performing it in the right manner. Saul did obtain what he saw to be the objective; defeat the Amalekites. God's objective was further into proving the obedience of Israel; Saul being chief.
2012 - pBiblx2 Field Wise Bible System Version 2.0.9d - GPL3