Let's consider the following SDE:
$$dX_t=X_t\mu dt+X_t\sigma dW_t \: \:\: \:\: \:(1)$$
This is shorthand for
$$X_t-X_0=\int_0^t X_s\mu ds + \int_0^t X_s\sigma dW_s \: \:\: \:\: \:(2)$$
My question is why in many books I've seen that people just divide both sides of (1) by $X_t$ to get
$$\frac{dX_t}{X_t}=\mu dt + \sigma dW_t$$
Is that transformation even correct? How can we reach this result from (2)?