The reason we teach this particular problem is to show that directional limits along straight lines are not enough. Along a straight line $y=mx,$ with $m \neq 0,$ we have $ f(x,mx) = \frac{2 x^2 y}{x^4 + y^2} = \frac{2 m x^3 }{x^4 + m^2 x^2} = \frac{2 m x }{x^2 + m^2} $ from which $ |f(x,mx) | = \left| \frac{2 m }{x^2 + m^2} \right| \cdot |x| \leq \left| \frac{2 m }{ m^2} \right| \cdot |x| = \left| \frac{2 }{ m} \right| \cdot |x|. $ Also, if we take either a vertical line $x=0$ or a horizontal line $y=0$ we get 0.
So, approaching the origin along any straight line gives an evident limit of 0. In one variable, that would be enough, but in at least two variables, that is not sufficient to show that there is a limit, just approach the origin along a parabola $y = m x^2$ instead, as in Davide's answer.