<s>[INST] First order DE, need help I am trying to solve this equation by inspection: $$(xy-y)dx+(x^2-2x+y)dy=0$$ Hints would be very helpful.. Thanks
 [/INST] first observe that $x-1=(xy - y)_y \neq (x^2-2x+y)_x = 2x - 2.$ so it is not a complete integral, but close.
here is one way to do this. write your system $$ \dfrac{dx}{dy} = \dfrac{x^2 - 2x + y}{(1-x)y}$$ as a system of two equations $$\dfrac{dx}{dt} = \dfrac{1}{1-x}, 
\dfrac{dt}{dy} = \dfrac{x^2 - 2x + y}{y}  $$
then the integrals are $$2x - x^2 = 2(t + C)$$ and 
substituting for $x$ we get a linear differential equation for $t$:
$$\dfrac{dt}{dy} = \dfrac{y - 2(t + C)}{y} = -\dfrac{2}{y}t +\left(1- \dfrac{2C}{y}\right) \tag 1$$ whose homogeneous solution is $t_H = \dfrac{B}{y^2}$ we will use variation of parameters to determine the solution for 
$t = \dfrac{B}{y^2}, \dfrac{dt}{dy} = \dfrac{1}{y^2} \dfrac{dB}{dy} - \dfrac{2B}{y^3} $ putting this in (1), we find $$\dfrac{dB}{dy} = y^2 - 2Cy$$ whose solution is $B = \dfrac{1}{3}y^3- Cy^2 + D$ and the solution for $t$ is $$ t = \dfrac{1}{3}y- C + \dfrac{D}{y^2}$$ 
eliminating the intermediate variable $t$ between $x$ and $y$ we find, $$2x - x^2 = 2( \dfrac{1}{3}y + \dfrac{D}{y^2}) \text{ where $D$ is an arbitrary constant}$$
</s>