Lemma 10.143.9. Let $\varphi : R \to S$ be a ring map. If $R \to S$ is surjective, flat and finitely presented then there exist an idempotent $e \in R$ such that $S = R_ e$.

First proof. Let $I$ be the kernel of $\varphi$. We have that $I$ is finitely generated by Lemma 10.6.3 since $\varphi$ is of finite presentation. Moreover, since $S$ is flat over $R$, tensoring the exact sequence $0 \to I \to R \to S \to 0$ over $R$ with $S$ gives $I/I^2 = 0$. Now we conclude by Lemma 10.21.5. $\square$

Second proof. Since $\mathop{\mathrm{Spec}}(S) \to \mathop{\mathrm{Spec}}(R)$ is a homeomorphism onto a closed subset (see Lemma 10.17.7) and is open (see Proposition 10.41.8) we see that the image is $D(e)$ for some idempotent $e \in R$ (see Lemma 10.21.3). Thus $R_ e \to S$ induces a bijection on spectra. Now this map induces an isomorphism on all local rings for example by Lemmas 10.78.5 and 10.20.1. Then it follows that $R_ e \to S$ is also injective, for example see Lemma 10.23.1. $\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).