"Missing the forest for the trees" is close, but moreso refers to failing to consider the whole because you're so focused on the parts. What I'm looking for is an idiom that describes mistaking the whole of something for one of its parts, rather than just failing to consider the whole at all.
A pop-culture example: the meme from this spongebob episode. Sandy is trying to defeat a predatory worm, but mistakes the tongue of the worm for the worm itself. I want a good idiom that expresses this specific failure.