Localization at prime ideals is a domain implies whole ring is a domain with connected spectrum

I'd like to show that if $R$ is a commutative ring with connected Spectrum then:

$R$ is a domain iff $R_{P}$ is a domain for all $P \in Spec(R)$ (where $R_P$ denotes localization at ideal $P$)

The $\Rightarrow$ direction is obvious. Let's suppose that $x,y \in R$ and $x \cdot y =0$ (both $x,y$ are nontrivial and we can assume that neither of them is nilpotent). Let $I_x,I_y$ denote annoihilators of $x,y$. If $V(I_x) \cap V(I_y)$ is not empty (i.e. there exists prime ideal containing both annihilators) I am able to achieve contradiction. Hence, let's suppose that $V(I_x) \cap V(I_y) = \emptyset$. Now my problem is I don't know whether there can exist prime ideal containing both $x,y$ - if there is no such ideal then $V(I_x),V(I_y)$ is an closed covering, which proves that Spec is not connected. How can I show that this is indeed the case?

• This must be wrong without an extra-condition like $R$ has finitely many minimal prime ideals. – user26857 Oct 13 '17 at 22:24

I think you will not be able to prove this, as there is a counterexample: https://stacks.math.columbia.edu/tag/0568. However, if you were to add the condition that $A$ was noetherian it would work.