Not all functions are created equal. Some get much simpler when differentiated, others get a little simpler, others don't really change, and a few actually get more complicated. You always want to pick $u$ to be the part that gets a lot simpler when differentiated, and $dv$ to be the part that doesn't mind being integrated. Then $\int v\, du$ will be simpler than $\int u \,dv$.
Functions like $\ln(x)$, $\frac{1}{x}$, $\tan^{-1}(x)$, $\frac{1}{1+x^2}$, $\sin^{-1}(x)$ and $\frac{1}{\sqrt{1-x^2}}$ almost never get grouped into $dv$. These functions either get a lot simpler when differentiated (like $\ln(x)$) or get a lot more complicated when integrated (like $1/x$).
Functions like $x^n$ (with $n>0$) get a little simpler when differentiated and a little more complicated when integrated. They sometimes get grouped into $u$ and sometimes into $dv$, depending on what else is in the integrand.
Functions like $\sin(x)$, $\cos(x)$ and $e^x$ stay more-or-less the same when differentiated or integrated. These get grouped into $dv$ more often than not.
A few functions, like $\sec^2(x)$, $x e^{x^2}$ and $x^{-n}$ (with $n$ at least 2), actually get simpler when integrated. These almost always get grouped into $dv$.
Don't forget that 1 is a function! You can always apply integration by parts to $\int f(x) \,dx$ by picking $u=f(x)$ and $dv= 1\, dx$. This gives the useful formula$$\int f(x) \,dx = x f(x) - \int x f'(x)\, dx$$that can be used to integrate $\ln(x)$ and $\tan^{-1}(x)$.