Let $R$ be an integral domain and $I,J$ be ideals such that $IJ$ is a principal ideal. Then $I$ is finitely generated? 
Let $R$ be an integral domain and $I,J$ be ideals such that $IJ$ is a principal ideal. Then is it true that $I$ is finitely generated ?

I was thinking like if $IJ=(a)$ , where $a=\sum_{i=1}^{k} x_iy_i$ , $x_i\in I , y_i \in J$ , then we might have $I=(x_1,...,x_k)$ , but I am not sure and I cannot proceed further . Please help , Thanks in advance
 A: If $J=(0)$, then $IJ=(0)$, so the statement that $IJ$ is principal imposes no restriction on $I$. This means that there is no reason for $I$ to be finitely generated. However, if $J\neq (0)$, then your claim is true, and here is how to continue your argument.
The statement is true if $I=(0)$, since $(0)$ is finitely generated. Now assume that $I\neq (0)\neq J$.
If $IJ=(a)$, then necessarily $a\neq 0$ because $R$ is a domain. We must have $a=\sum_{i=1}^{k} x_iy_i$ , $x_i\in I , y_i \in J$. Let $I_0=(x_1,\ldots,x_k)$ and $J_0=(y_1,\ldots,y_k)$. We must have $I_0\subseteq I$ and $J_0\subseteq J$, and the goal is to show that we also have $I\subseteq I_0$.
Choose any $x\in I$. Since $xy_i\in IJ=(a)$ for $1\leq i\leq k$ there must exist $r_i\in R$ such that $xy_i=r_ia$ for $1\leq i\leq k$. Multiplying by $x_i$ yields $xx_iy_i=r_ix_ia$. Summing this equality as $i$ ranges from $1$ to $k$ yields $xa=x(\sum x_iy_i) = (\sum r_ix_i)a$. From the domain property, we may cancel $a$ to obtain $x=\sum_{i=1}^k r_ix_i\in I_0$. This proves $I\subseteq I_0$, as required.
EDIT. January 21, 2022.
I will address some criticisms from the comments that were posted yesterday. Let me copy the statements and then respond to them.
(1): I just want to add that this solution assumes that the ring R has the unit 1. If it didn't have the unit 1, then $a$ doesn't need to decompose into $\sum_{i=1}^k x_iy_i$. Maybe I am wrong, but if I am then this proof has a "whole" or I just don't know some basic stuff. –
donaastor
(2): Yeah, I was right. The statement is false for "rngs". Take $R=2\cdot \mathbb Z$ (even numbers). Take $I=(2)$ (all numbers divisible by 4) and $J$ to be all numbers divisible by $6$. Now $I\cdot J=(12)$, but $12$ can't be decomposed into the wanted sum because whenever $a\in I$ and $b\in J$, we have $24|ab$. In addition, $J$ is not finitely generated (you can never get $6$), so it is a counter-example. –
donaastor
First let's agree on definitions (as they pertain to commutative rings):
(1) An integral domain is a commutative, unital ring with no nonzero zero-divisors. In order to address the criticisms, let's also allow nonunital rings in this definition.
(2) If $R$ is a ring and $X\subseteq R$, then $(X)$ denotes the least ideal of $R$ containing the set $X$. In particular, for $a\in R$, $(a)$ is the least ideal of $R$ containing the element $a$. 
If $R$ is unital, then one can prove that $(a) = Ra = \{ra\;|\;r\in R\}$. 
If $R$ is nonunital, then one can prove that $(a) = \mathbb Za+Ra = \{na+ra\;|\;n\in\mathbb Z, r\in R\}$.
(3) The product of two ideals $I$ and $J$ is the least ideal of $R$ containing all the products $xy, x\in I, y\in J$. One can prove that $IJ = (\{x_iy_j\}) = \{\sum_{i=1}^k x_iy_i\;|\;x_i\in I, y_j\in J\}$ whether $R$ is unital or not.
Now let me take the criticisms one at a time.
(A) this solution assumes that the ring $R$ has the unit $1$.

Yes, I WAS assuming that $R$ had $1$ when I wrote the solution, but that assumption does not affect the proof in any way except on the first line of the 3rd paragraph. Where I write "there must exist $r_i\in R$" one should should instead write "there must exist $r_i\in \mathbb Z+R$" in the nonunital case. In all other aspects, the proof given works for nonunital rings.
(B) If it didn't have the unit 1, then $a$ doesn't need to decompose into $\sum_{i=1}^k x_iy_i$.  
This is a false statement.
(C) The statement is false for "rngs".
This is a false statement.
Moreover there can be no counterexample constructed as a nonunital subring of $\mathbb Z$ since all additive subgroups of $\mathbb Z$ are cyclic (hence any ideal of any nonunital subring must be finitely generated).
To conclude, I assert that the proof given works equally well for unital or nonunital integral domains with the one minor change I noted above in (A). That is, one way to derive the result for nonunital rings from the above proof for unital rings is to make a small change.
There is a second (better) way to derive a proof for the nonunital case from a proof for the unital case. One can apply a general "transfer principal" that shows that, for many types of statements, the statement is true for integral domains in the unital case iff it is true also in the nonunital case. This result is derivable from the paper 
Szendrei, J.
On the extension of rings without divisors of zero.
Acta Univ. Szeged. Sect. Sci. Math. 13 (1950), 231-234.
The paper, which focuses on not-necessarily-commutative rings,
proves that the "unital completion" of a domain is a domain. In the commutative case it means this: for each nonunital integral domain $R$ there is an extension $\widehat{R}$ of $R$, which is unique up to isomorphism over $R$, with the properties that (i) $\widehat{R}$ is an unital integral domain containing $R$ as an ideal, (ii) $\widehat{R}$ is generated as a ring by $R\cup \{1\}$, (iii) there is no subring lying strictly between $R$ and $\widehat{R}$, (iv) the ideals of $R$ are exactly the ideals of $\widehat{R}$ that are contained in $R$, ideal generation and ideal product work the same way for ideals of $\widehat{R}$ contained in $R$, ETC.
This can used as follows: assume the problem is stated for nonunital $R$. Apply my original proof to the unital completion $\widehat{R}$ for ideals $I, J\subseteq R$. Deduce the result for $\widehat{R}$, and then see that the result has the same meaning for $R$.
