Solving $u''(x)-\frac{u'(x)^2}{u(x)}+\frac{u'(x)}{x}=u(x)^2$ I am looking to solve the following ODE:
$$u''(x)-\frac{u'(x)^2}{u(x)}+\frac{u'(x)}{x}=u(x)^2.$$
As far as I can see, none of the common methods to solve ODEs (separation of variables, integrating factor, Laplace transform, etc.) yield anything useful.
Can I have some guidance on how to solve this equation?
EDIT: I have, with the help of computer algebra systems, found the solution to this equation to be
$$u(x)=\frac{\mathrm{e}^{AB}A^4x^{A-2}}{\left(x^A-\frac{A^2}2\mathrm{e}^{AB}\right)^2}$$
for arbitrary constants $A$ and $B$. However, I am still lost on how one might arrive at this solution. Any ideas?

$\def\d{\mathrm{d}}$From the original equation $\dfrac{\d^2 u}{\d x^2} - \dfrac{1}{u} \left( \dfrac{\d u}{\d x} \right)^2 + \dfrac{1}{x} \dfrac{\d u}{\d x} = u^2$, letting $v = \dfrac{1}{ux^2}$ as @ClaudeLeibovici does yields$$
x^2 v \frac{\d^2 v}{\d x^2} - x^2 \left( \frac{\d v}{\d x} \right)^2 + xv \frac{\d v}{\d x} + v = 0,
$$
and letting $y = \ln x$ yields\begin{align*}
v \frac{\d^2 v}{\d y^2} - \left( \frac{\d v}{\d y} \right)^2 + v = 0.\tag{1}
\end{align*}
Denoting $w = \dfrac{\d v}{\d y}$, (1) is equivalent to the following autonomous system:$$
\begin{cases}
\dfrac{\d v}{\d y} = w\\
\dfrac{\d w}{\d y} = \dfrac{w^2}{v} - 1
\end{cases},
$$
and\begin{align*}
\frac{\d w}{\d v} = \frac{1}{w} \left( \dfrac{w^2}{v} - 1 \right) \Longrightarrow (v - w^2) \,\d v + vw \,\d w = 0.\tag{2}
\end{align*}
The integrating factor of (2) is $\dfrac{1}{v^3}$, thus the solution to (2) is $\dfrac{w^2 - 2v}{2v^2} = C_1$, where $C_1$ is a constant. Now,$$
\frac{\d v}{\d y} = w = \pm\sqrt{\smash[b]{2C_1 v^2 + 2v}},
$$
which can be solved explicitly (with a lot of calculation).
