Stories of Moshe obtaining water from a rock appear twice in the Torah, in Exodus 17 and Numbers 21. In both stories he hits the rock, but in the second he was supposed to speak to it and was punished for hitting it. Is this a case of two versions of the same story coming from different sources, as some biblical critics have suggested? The following is from the standard Reform commentary on the Torah.
W. Gunther Plaut, The Torah: A Modern Commentary, p. 1155:
This is the second murmuring to take place at Meribah, the first being reported in Exod. 17:1-7, and in both instances water is miraculously provided from a rock. Bible critics have, therefore, suggested that we have here two version of the same story. However, such a conclusion is highly speculative. It is equally likely that a return to the old resting place, which had seen a popular upheaval many years before, evoked memories and frustrations and led to a renewed complaint against the leaders who seemed to keep Israel forever in the desert. In fact, the focus here is less on the discontent of the people and more on the failure of leadership...