21:79
فَفَهَّمْنَٰهَا سُلَيْمَٰنَ ۚ وَكُلًّا ءَاتَيْنَا حُكْمًۭا وَعِلْمًۭا ۚ وَسَخَّرْنَا مَعَ دَاوُۥدَ ٱلْجِبَالَ يُسَبِّحْنَ وَٱلطَّيْرَ ۚ وَكُنَّا فَٰعِلِينَ
And We gave understanding of the case to Solomon, and to each [of them] We gave judgement and knowledge. And We subjected the mountains to exalt [Us], along with David and [also] the birds. And We were doing [that].
Translation · Saheeh International
Tafsir
Ibn Kathīr (abridged)
Dawud and Sulayman and the Signs which They were given; the Story of the People whose Sheep pastured at Night in the Field
Abu Ishaq narrated from Murrah from Ibn Mas`ud: "That crop was grapes, bunches of which were dangling." This was also the view of Shurayh. Ibn `Abbas said: "Nafash means grazing." Shurayh, Az-Zuhri and Qatadah said: "Nafash only happens at night." Qatadah added, "and Al-Haml is grazing during the day."
وَدَاوُودَ وَسُلَيْمَـنَ إِذْ يَحْكُمَانِ فِى الْحَرْثِ إِذْ نَفَشَتْ فِيهِ غَنَمُ الْقَوْمِ
(And (remember) Dawud and Sulayman, when they gave judgement in the case of the field in which the sheep of certain people had pastured at night;) Ibn Jarir recorded that Ibn Mas`ud said: "Grapes which had grown and their bunches were spoiled by the sheep. Dawud (David) ruled that the owner of the grapes should keep the sheep. Sulayman (Solomon) said, `Not like this, O Prophet of Allah!' Dawud said, `How then' Sulayman said: `Give the grapes to the owner of the sheep and let him tend them until they grow back as they were, and give the sheep to the owner of the grapes and let him benefit from them until the grapes have grown back as they were. Then the grapes should be given back to their owner, and the sheep should be given back to their owner.' This is what Allah said:
فَفَهَّمْنَـهَا سُلَيْمَـنَ
(And We made Sulayman to understand (the case).)" This was also reported by Al-`Awfi from Ibn `Abbas.