A judge can give judgements for the people according to his knowledge
بَابُ مَنْ رَأَى لِلْقَاضِي أَنْ يَحْكُمَ بِعِلْمِهِ فِي أَمْرِ النَّاسِ إِذَا لَمْ يَخَفِ الظُّنُونَ وَالتُّهَمَةَ
Sahih al-Bukhari, Book of Judgments (Ahkaam)(view book)
Sahih al-Bukhari 7161
Narrated 'Aisha:
Hind bint 'Utba bin Rabia came and said. "O Allah's Apostle! By Allah, there was no family on the surface of the earth, I like to see in degradation more than I did your family, but today there is no family on the surface of the earth whom I like to see honored more than yours." Hind added, "Abu Sufyan is a miser. Is it sinful of me to feed our children from his property?" The Prophet ﷺ said, "There is no blame on you if you feed them (thereof) in a just and reasonable manner.
حَدَّثَنَا أَبُو الْيَمَانِ، أَخْبَرَنَا شُعَيْبٌ، عَنِ الزُّهْرِيِّ، حَدَّثَنِي عُرْوَةُ، أَنَّ عَائِشَةَ ـ رضى الله عنها ـ قَالَتْ جَاءَتْ هِنْدٌ بِنْتُ عُتْبَةَ بْنِ رَبِيعَةَ فَقَالَتْ يَا رَسُولَ اللَّهِ، وَاللَّهِ مَا كَانَ عَلَى ظَهْرِ الأَرْضِ أَهْلُ خِبَاءٍ أَحَبَّ إِلَىَّ أَنْ يَذِلُّوا مِنْ أَهْلِ خِبَائِكَ، وَمَا أَصْبَحَ الْيَوْمَ عَلَى ظَهْرِ الأَرْضِ أَهْلُ خِبَاءٍ أَحَبَّ إِلَىَّ أَنْ يَعِزُّوا مِنْ أَهْلِ خِبَائِكَ. ثُمَّ قَالَتْ إِنَّ أَبَا سُفْيَانَ رَجُلٌ مِسِّيكٌ، فَهَلْ عَلَىَّ مِنْ حَرَجٍ أَنْ أُطْعِمَ الَّذِي لَهُ عِيَالَنَا قَالَ لَهَا " لاَ حَرَجَ عَلَيْكِ أَنْ تُطْعِمِيهِمْ مِنْ مَعْرُوفٍ ".