Problem in understanding the solution of exact differential $M(x,y)dx + N(x,y)dy = du(x,y)$. If $M(x,y)dx + N(x,y)dy = du(x,y)$, then it is an exact differential equation. For that to happen, $$\left(\dfrac{\partial M(x,y)}{\partial y}\right)_x =\left(\dfrac{\partial N(x,y)}{\partial x}\right)_y \tag1.$$  
I was following Differential Equations by  Balachandra Rao, S. Staff to see how to find $u(x,y)$. For most of the part but one, I could conceive.
The proof goes using  the first part of $(1)$ after integrating it to get $$u(x,y) = \int M(x,y) dx + \phi (y).$$ In order to satisfy the second condition of $(1)$, there exists a certain $\phi (y)$. So, $$\frac{\partial u(x,y)}{\partial y} = \frac{\partial}{\partial y}\left[\int M(x,y) dx\right]+ \phi'(y)$$ which must be equal to $$N(x,y) = \frac{\partial}{\partial y}\left[\int M(x,y) dx\right]+ \phi'(y) \implies \phi'(y) = N(x,y) - \frac{\partial}{\partial y}\left[\int M(x,y) dx\right] .$$ LHS is independent of $x$; so RHS must also be independent of $x$; in order to verify this, we take the partial derivative of RHS w.r.t. $x$ : $$\frac{\partial}{\partial x} \left[N(x,y) - \frac{\partial}{\partial y}\left[\int M(x,y) dx\right]\right] = \dfrac{\partial N(x,y)}{\partial x} -\dfrac{\partial M(x,y)}{\partial y}= 0.$$ So, RHS is independent of $x$. Then by integrating, we get $$\phi(y) = \int\left[N(x,y) -\frac{\partial}{\partial y}\left[\int M(x,y) dx \right] \right]dy + C .$$ Putting the value of $\phi(y)$, we get $$u(x,y) = \int M(x,y) dx + \int\left[N(x,y) -\frac{\partial}{\partial y}\left[\int M(x,y) dx \right] \right]dy.$$ This is the value of $u(x,y)$ . 
But the book presents the working rule as 

A "working rule" convenient to apply for solving an exact differential equation is as follows: $$\underset{[y\; \text{const.}]}{\int M dx} + [\color{red}{\text{Terms of} \; N\; \text{not containing} \; x}] dy = c$$

See the red marked statement; $M(x,y)$ is not there, but in the derivation the parenthesis contained $\dfrac{\partial}{\partial y}\left[\int M(x,y) dx \right] $. As if it was excluded in the working rule without specifying any reason. If I break $$\int\left[N(x,y) -\frac{\partial}{\partial y}\left[\int M(x,y) dx \right] \right]dy$$ into $$\int N(x,y) dy - \int \frac{\partial}{\partial y}\left[\int M(x,y) dx \right] dy$$, then I get $$\int N(x,y) dy - \frac{\partial}{\partial y}\left[\int M(x,y) dx \right].$$ The second term $$-\frac{\partial}{\partial y}\left[\int M(x,y) dx \right]$$ is absent in the red-marked statement. What is the reason for its exclusion ? Please help. 
 A: I think
$$\int N(x,y)dy$$
will still contain $x$ because $N$ is a function of $x$ and $y$. But if it were combined with
$$−\dfrac{∂}{∂y}\left[\int M(x,y)dx\right]$$
the terms containing $x$ would probably cancel so that:
$$\left[ N(x,y) −\dfrac{∂}{∂y}\left[\int M(x,y)dx\right]\right] = f(y)$$ which would be free from $x$; while
$$\left[ M(x,y) −\dfrac{∂}{∂x}\left[\int N(x,y)dy\right]\right] = f(x)$$ would be free from y.
I am new to this topic but I am trying to do my best to understand it..
That's why I came upon this site
It says here:

Formula for general solution of exact equation $M dx + N dy = 0$. The general solution is given by $$\int M ∂x + \int f(y)dy = C$$
where $f(y)$ is composed of all the terms in $N$ which are free from $x$ (i.e. all terms not containing $x$ — terms containing $y$ only or constants) and $\int M ∂x$ denotes integration with respect to $x$, keeping $y$ constant.
Alternate formula: $$\int N ∂y + \int f(x)dx = C$$
where $f(x)$ is composed of all the terms in $M$ which are free from $y$.
The above formulas will give the correct result in the vast majority of cases but they are not infallible and in exceptional cases may give an incorrect result. Consequently the solution should always be checked by substituting it into the original equation.

