Allaah (The Most High) said:
وَٱتۡلُ عَلَيۡهِمۡ نَبَأَ ٱلَّذِىٓ ءَاتَيۡنَـٰهُ ءَايَـٰتِنَا فَٱنسَلَخَ مِنۡهَا فَأَتۡبَعَهُ ٱلشَّيۡطَـٰنُ فَكَانَ مِنَ ٱلۡغَاوِينَ
”And recite (O Muhammad) to them the story of him to whom We gave Our Ayat (proofs, evidences, verses, lessons, signs, revelations, etc.), but he threw them away, so Shaitan (Satan) followed him up, and he became of those who went astray.” [7:175]
وَلَوۡ شِئۡنَا لَرَفَعۡنَـٰهُ بِہَا وَلَـٰكِنَّهُ ۥۤ أَخۡلَدَ إِلَى ٱلۡأَرۡضِ وَٱتَّبَعَ هَوَٮٰهُۚ فَمَثَلُهُ ۥ كَمَثَلِ ٱلۡڪَلۡبِ إِن تَحۡمِلۡ عَلَيۡهِ يَلۡهَثۡ أَوۡ تَتۡرُڪۡهُ يَلۡهَثۚ ذَّٲلِكَ مَثَلُ ٱلۡقَوۡمِ ٱلَّذِينَ كَذَّبُواْ بِـَٔايَـٰتِنَاۚ فَٱقۡصُصِ ٱلۡقَصَصَ لَعَلَّهُمۡ يَتَفَكَّرُونَ
”And had We willed, We would surely have elevated him therewith but he clung to the earth and followed his own vain desire. So his description is the description of a dog: if you drive him away, he lolls his tongue out, or if you leave him alone, he (still) lolls his tongue out. Such is the description of the people who reject Our Ayat (proofs, evidences, verses, lessons, signs, revelations, etc.). So relate the stories, perhaps they may reflect.’’ [7:176]
Allaah likens him—[the one whom He gave knowledge of the Book and taught him knowledge which was not given to others, but he abandoned it; followed his desires and preferred the Anger of Allaah over the Pleasure of Allaah; preferred the worldly life over the afterlife and preferred the created beings over the Creator]—to a dog, which is considered to be from the meanest of animals; the lowest in status and the meanest in inclination.
Its desire does not exceed beyond its stomach (i.e. its desire for food). It is considered to among the greediest (of animals) and most eager (for food). And due to its eagerness (for food), it does not go about except that it places its nose on the ground, whilst sniffing and roaming about greedily and eagerly. It does not cease smelling its anus besides all its other body parts. If a stone is thrown at it, it returns to bite it due to extreme greed. When it takes possession of a dead animal enough for a hundred dogs, it would not allow another dog to eat anything from it, except whilst growling and seeking to gain the upper hand due to eagerness, greed and covetousness.
In this parable about the one likened to a dog that constantly lolls its tongue out—[the one who gave precedence to this worldly life and its quick fading enjoyment over the afterlife despite his abundant knowledge of the Book]—there is a marvellous underlying reason. And that is because this person whom Allaah mentioned as one who abandoned the verses of Allaah and followed his desires, he (only) did so out of severe eagerness for the worldly life and due his heart being separated from Allaah and the afterlife. He is extremely eager for it and his eagerness is similar to the constant eagerness of a dog whether it is troubled or left alone.
[Source: بدائع التفسير الجامع لما فسَّره الإمام ابن القيم الجوزية Abridged and slightly paraphrased. Vol 1. Page: 426]