How would you solve this ODE?

ode=D[y[x],x]==x/(x-y[x])

How does Mathematica come up with this solution?

sol=DSolve[ode,y[x],x]

Let us try a few changes of variables: run TMF064.Package.m first !

Polar coordinates with r = r(ϕ):

ChangeOfVariables[{ode},
{x->r[ϕ]Cos[ϕ],y[x]->r[ϕ]Sin[ϕ]},
{x},{y},
{ϕ},{r},
showAll=1
]

Polar coordinates with ϕ =ϕ(r):

ChangeOfVariables[{ode},
{x->r Cos[ϕ[r]],y[x]->r Sin[ϕ[r]]},
{x},{y},
{r},{ϕ},
showAll=1
]

Scaling invariant r = y / x and s = s(r) = y:

ChangeOfVariables[{ode},
{x->s[r]/r,y[x]->s[r]},
{x},{y},
{r},{s},
showAll=1
]

Scaling invariant r = y / x and s = s(r) = y:

betterODE=ChangeOfVariables[{ode},
{x->Exp[s[r]]/r,y[x]->Exp[s[r]]},
{x},{y},
{r},{s},
showAll=1
]
Solve[betterODE,D[s[r],r]]

DSolve[betterODE,s[r],r]