When faced with a difficult case of Torah law, the Torah tells us to go to “hakohanim halevi’im, v’el hashofet” (17:8), and warns not to stray from the advice of “hakohen ha’omeid l’shareis es Hashem Elokecha, oh el hashofet”(17:12). The role of “shofet”, referring to the Sanhedrin in Yerushalayim, the “court of last resort”, is obvious in determining the final word on matters of halacha, but what is the role of the “kohen” in this process? And as if to head of our interpreting the “kohen” here as Torah-teacher, the Torah stresses the ritual role of kohen, the one who is “omeid l’shareis”, a servent in the Mikdash.
Perhaps the message of the parsha is that investigation into Torah law should be pursued not just as a quest for knowledge, but as a quest for religious inspiration and insight. Doubt about Torah law is not just a result of lack of information, but is also a result spiritual accomplishment not yet been attained.
The “shofet” can instruct and inform, but without the “kohen” to uplift, knowledge is sterile and incomplete, and doubt cannot be overcome. Only when their message is taken together can the kohen and shofet resolve the difficulties we bring before them. (based on Maor v'Shemesh)