Lemma 49.2.1. Let $A \to B$ be a quasi-finite ring map. Given two factorizations $A \to B' \to B$ and $A \to B'' \to B$ with $A \to B'$ and $A \to B''$ finite and $\mathop{\mathrm{Spec}}(B) \to \mathop{\mathrm{Spec}}(B')$ and $\mathop{\mathrm{Spec}}(B) \to \mathop{\mathrm{Spec}}(B'')$ open immersions, there exists an $A$-subalgebra $B''' \subset B$ finite over $A$ such that $\mathop{\mathrm{Spec}}(B) \to \mathop{\mathrm{Spec}}(B''')$ an open immersion and $B' \to B$ and $B'' \to B$ factor through $B'''$.

Proof. Let $B''' \subset B$ be the $A$-subalgebra generated by the images of $B' \to B$ and $B'' \to B$. As $B'$ and $B''$ are each generated by finitely many elements integral over $A$, we see that $B'''$ is generated by finitely many elements integral over $A$ and we conclude that $B'''$ is finite over $A$ (Algebra, Lemma 10.36.5). Consider the maps

$B = B' \otimes _{B'} B \to B''' \otimes _{B'} B \to B \otimes _{B'} B = B$

The final equality holds because $\mathop{\mathrm{Spec}}(B) \to \mathop{\mathrm{Spec}}(B')$ is an open immersion (and hence a monomorphism). The second arrow is injective as $B' \to B$ is flat. Hence both arrows are isomorphisms. This means that

$\xymatrix{ \mathop{\mathrm{Spec}}(B''') \ar[d] & \mathop{\mathrm{Spec}}(B) \ar[d] \ar[l] \\ \mathop{\mathrm{Spec}}(B') & \mathop{\mathrm{Spec}}(B) \ar[l] }$

is cartesian. Since the base change of an open immersion is an open immersion we conclude. $\square$

In your comment you can use Markdown and LaTeX style mathematics (enclose it like $\pi$). A preview option is available if you wish to see how it works out (just click on the eye in the toolbar).