Let $\pi: X \rightarrow Y$ be a finite type morphism of noetherian normal schemes and let $D$ be a prime Weil divisor in $Y$. It seems to be a well known fact that if $\pi$ is flat, then $\pi$ pulls back Weil divisor classes in the sense that then is a morphism of abelian groups, $$ \pi^*: \text{Cl}(Y) \longrightarrow \text{Cl}(X) $$ defined on prime Weil divisor classes $\pi^{*}([D]) = [\pi^{-1}(D)]$ and extended linearly. I am having trouble finding an actual proof or explanation of this fact beyond just stating it is true in most algebraic geometry texts.
My attempt to prove it myself has just been via the going-down property for flat ring morphisms. Restricting to affines $\operatorname{Spec}A \subseteq Y$ and $\operatorname{Spec} B \subseteq X$ with $\pi(\operatorname{Spec} B) \subseteq \operatorname{Spec}A$, if $\eta \in \operatorname{Spec}A$ is the generic point of a prime divisor then it corresponds to a height $1$ prime ideal $\mathfrak{p}$ in $A$. But then it seems like going-down only gives me that the primes in the preimage $\pi^{-1}(\overline{\{ \eta \}})$ must have height at least $1$. but surely this isn't enough to give me that it is a divisor. Is anyone able to tell me if I am even on the right track? I'm not even completely sure if going-down comes into it.
You can get the other inequality from dimension theory. In particular, we have the following theorem
As you note, if we assume $\pi$ is flat, then Going-Down implies that we actually get an equality.
Finally, we apply this when $q$ is the generic point of a $D$ and $p$ is a generic point of an irreducible component of $\pi^{-1}(D)$. In this case, we have $\operatorname{codim}_{\pi^{-1}(q)} p =0$.