Recall that for $\alpha \neq -1$, we have
$$\int (ax+b)^{\alpha}dx = \dfrac1a \cdot \dfrac{(ax+b)^{\alpha+1}}{\alpha+1} + \text{ constant}$$
A way to see the above is as follows. Let $y = ax+b$. We then have $dy = adx$. Hence for $\alpha \neq -1$,
$$\int (ax+b)^{\alpha}dx = \int y^{\alpha} \dfrac{dy}a = \dfrac1a \dfrac{y^{\alpha+1}}{\alpha+1} + \text{ constant} = \dfrac1a \dfrac{(ax+b)^{\alpha+1}}{\alpha+1} + \text{ constant}$$
If $\alpha = -1$, we then have
$$\int \dfrac{dx}{ax+b} = \dfrac{\log(ax+b)}a + \text{ constant}$$
In general, there is no easy way to get $$\int \sqrt{P(x)} dx,$$ if degree of $P(x)$ is greater than $2$.
If $P(x)$ is linear, i.e., has degree $1$, I have mentioned above how to proceed.
Below we will see how to proceed if $P(x)$ is quadratic, i.e., $$P(x) = ax^2 + bx + c = a ((x+b_1)^2 + c_1).$$
$$b_1=\frac{a}{2b}$$ $$c_1=\frac{c}{a}-b_1^2$$
We now have the following
$$\sqrt{P(x)} = \sqrt{a} \sqrt{(x+b_1)^2 \pm c_1}$$
which gives us that
$$\int \sqrt{P(x)} dx = \sqrt{a} \int \sqrt{(x+b_1)^2 + c_1} dx$$
and
$$\int \sqrt{(x+b_1)^2 + c_1} dx = \dfrac{(b_1+x)\sqrt{P(x)} + c_1 \log \left(b_1 + x + \sqrt{P(x)}\right)}2 + \text{constant}$$