I know that if $F(x,y)$ is a function of two variables and $\frac{\partial F}{\partial x}=g(x,y)$ then it follows that
$$F(x,y)=\int g(x,y)dx+h(y)\cdots(1)$$ for some function $h$ of $y$ and $\int g(x,y)dx$ has been evaluated keeping $y$ fixed.
I am having trouble to understand why $(1)$ follows?
Is there any related result or theorem that enable us to write $(1)$ under given condition?