Can proof for the resurrection of the dead be proved from this posuk?
(31,16) “And Hashem said to Moshe: Behold, you are about to lie with your forefathers, and this people will rise up and stray after the foreign gods of the land into which they are coming, and they will forsake Me and violate My covenant which I have made with them.”
The gemora in Sanhedrin 90b writes that the Romans asked R. Yehoshua ben Chananiah: From where do we know that the Holy One, Blessed be He, will resurrect the dead and that He knows the future? He replied: Both of them can be learned from this verse - “And Hashem said to Moshe: Behold you are about to lie wih your forefathers and rise up (thus there will be resurrection of the dead); and this people shall stray after the foreign gods (thus Hashem knows the future)”. They challenged that perhaps the posuk is to be read “this people will rise up and stray”? He replied: You have the answer to half of your question - that He knows the future.
There are several difficulties with this gemora - how could they ask if Hashem knows the future when even the prophets foretold the future, why did he choose this posuk to bring his proof, and what exactly did R. Yehoshua mean when he replied that they have the answer to half their question?
But we can explain that their question was the same difficulty that the Rambam and other earlier Rabbis dealt with, that Hashem’s knowing the future and our having freewill are a contradiction to each other. Because if He knows what will happen in the future, how can we have freewill to choose what to do? Conversely, if we have the freewill to choose what to do, how can Hashem know the future? This is why they were asking if Hashem knew the future.
But Chazal teach that everything is in the hands of Heaven apart from the fear of Heaven, and thus it is not predetermined at the time of conception whether a person will be righteous or wicked. Therefore, their question was only if Hashem knows whether or not a person will sin in the future, because there is no question that Hashem knows the future concerning everything else since everything else is in the hands of Heaven.
Now, earlier in the gemora in Sanhedrin it brings a proof for the resurrection of the dead from the posuk “and you shall give from it the terumah of Hashem to Aharon the Kohen” (Bamidbar 18:28), which is problematic since Aharon died before they entered Eretz Yisrael where terumah could have been given to him. Therefore, the posuk must be saying that they will give terumah to Aharon after the resurrection of the dead.
However, since the Romans were questioning whether Hashem knows if a person will sin in the future R. Yehoshua could not bring a proof to the resurrection of the dead from Aharon, because perhaps Hashem does not know the future and so did not know that Aharon would sin with the waters of Merivah. Thus Hashem would have assumed that Aharon would enter Eretz Yisrael in his lifetime and be given terumah.
Therefore, he brought a proof from our posuk instead, and when they challenged his reading of the posuk he replied that even according to their reading of the posuk they have answered half of their question, that Hashem knows whether a person will sin in the future. Thus, the resurrection of the dead can now be proved from Aharon.