Pullback of ring localizations. In what follow let $R$ be a commutative ring with unit and let $S_1$ and $S_2$ two saturated multiplicative subsets (by saturated I mean that in the localization morphism $i_{S_i} \colon R \to S_i^{-1}R$ the elements $a \in R$ such that $i_{S_i}(a)$ is invertible are exactly and only those in $S_i$).
We have the following pullback diagram of rings
$$
\require{AMScd}
\begin{CD}
P @>{\pi_1}>> S_1^{-1}R \\
@V{\pi_2}VV   @VV{j_{S_1,S_1\cdot S_2}}V \\ 
S_2^{-1}R @>>{j_{S_2,S_1\cdot S_2}}> (S_1 \cdot S_2)^{-1}R 
\end{CD}
$$
where the morphisms $j_{S_i,S_1 \cdot S_2}$ are the obvious localizations morphisms and $S_1 \cdot S_2$ is the multiplicative set made of the products of elements of $S_1$ and $S_2$.
Here are the questions:
1. Is it always true that $P$ is of the form $S^{-1}R$ for some multiplicative set $S \subseteq R$
I've proven that this is true if $R$ is a unique factorization domain, but the proof relies on the existance of a canonical representation of the elements of the $S^{-1}R$ as fractions of coprime elements of $R$.
2. Is $P$ of the form $S^{-1}R$ if $R$ is an integral domain (even if it is not a UFD)?.
Thanks in advance for any help.
 A: Evidently when $S = S_1 \cap S_2$, we have an injection $S^{-1}R \rightarrow P$.  When is this an isomorphism?  As you rightly point out, when $R$ is a UFD, then we have an isomorphism.  You can weaken the UFD assumption slightly — the same proof works if you assume that $R$ is GCD domain.
Another class of rings for which $S^{-1}R \rightarrow P$ is an isomorphism are Dedekind domains with torsion class groups (such as rings of integers of number fields).  Given $a/s_1 = b/s_2$, let $J = s_1R + s_2R$, i.e. the GCD of the principal ideals generated by $s_1$ and $s_2$.  Now find $n$ such that $J^n$ is a principal ideal, and choose $s$ such that $sR = J^n$.  Then $s \in S$ and now we can find $c$ such that $c/s = a/s_1 = b/s_2$.
Requiring the class group to be torsion is necessary.  For example, suppose prime ideal $P$ is not finite order in the class group.  Let prime ideals $Q_1$ and $Q_2$ be ideals in the inverse class $[P]^{-1}$.  Let $S_i$ be all elements not in any prime ideal except $P$ and $Q_i$ for $i = 1$ and $2$.  Since $P$ is not finite order in the class group, it is contained in the union of all other prime ideals (see Can a prime in a Dedekind domain be contained in the union of the other prime ideals?).  Therefore $S$ will not contain any elements of $P$ and will be trivial.  Therefore $S^{-1}R = R$ and will not surject onto $P$.
