As different as these two incidents might seem at first look, they are showing the same thing: requests to God do not go unheeded. At the Rephidim encampment there was no water. Water is big. Water is necessary. It's not just nice to have; you die without it. The Israelites looked at their children and their thirsty animals and turned on Moses. "Is the Lord with us or not?" they demanded. But the Lord heard them. The Lord would always provide. He instructed Moses to strike a rock with his staff. Moses did, and there was water. Enough water for somewhere over a million people and their livestock. This was not a light trickle... This was also the place where the Amalekites attacked the Israelites. What a shock that must have been! Who were these people, the Amalekites? They had been around for awhile. The first time we see them is in the series of battles between the two alliances in Genesis 14, when Lot is taken captive and Abraham has to go rescue him. This was a tribe of people that lived in Arabia Petraea, between the Dead Sea and the Red Sea. They were not the descendants of Amalek, the son of Eliphaz, for they existed in the days of Abraham (Gen. 14:7). They were probably a tribe that migrated from the shores of the Persian Gulf and settled in Arabia. "They dwelt in the land of the south...from Havilah until thou comest to Shur" (Num. 13:29; 1 Sam. 15:7). They were apparently a pastoral, and therefore probably a nomadic people. Their kings bore the hereditary name of Agag (Num. 24:7; 1 Sam. 15:8). They attempted to stop the Israelites when they marched through their territory (Deut. 25:18), attacking them at Rephidim (Ex. 17:8-13; compare Deut. 25:17; 1 Sam. 15:2). Afterwards, they attacked the Israelites at Hormah (Num. 14:45). We read of them subsequently as being in league with the Moabites (Judg. 3:13) and the Midianites (Judg. 6:3). Saul finally desolated their territory and destroyed their power (1 Sam. 14:48; 15:3), and David recovered booty from them (1 Sam. 30:18-20). In the Babylonian inscriptions they are called "Sute," in those of Egypt "Sittiu," and the Amarna tablets include them under the general name of "Khabbati," or "plunderers." from http://www.christiananswers.net/dictionary/amalekite.html In the battle against the attacking Amalekites, Moses picks Joshua to lead the military. From the NIV study notes we read, Joshua was from the tribe of Ephraim (Numbers 13:8), one of the most powerful of the 12 tribes. Joshua's military prowess uniquely suited him to be the conqueror of Canaan 40 years later, while his faith in God and loyalty to Moses suited him to be Moses' aide and successor. In this battle, as long as Moses' hands are raised in supplication to God, the Israelites continue to win. Then the Lord tells Moses to write down what happened. Why? "...because I will completely blot out the memory of Amalek from under heaven." And except for the writings of Moses and other biblical authors, the world does not remember them today. We have their name remembered, but nothing else.