I would like to solve the following exercise (2.26) from Atiyah & MacDonald's "Introduction to Commutative Algebra":
If $M$ is an $A$-module (where $A$ is a commutative ring), then: $$M \text{ is flat} \iff \text{Tor}_1(M,A/\mathfrak{a}) = 0 \text{ for all finitely generated ideals } \mathfrak{a}\subset A$$
I managed to prove that: $$M \text{ flat } \iff \text{Tor}_1(M,A/\mathfrak{a}) = 0 \text{ for all ideals } \mathfrak{a}\subset A$$
Any solutions or suggestions on how to proceed would be much appreciated.
So you want to show that $\operatorname{Tor}_1(M,A/\mathfrak{a}) = 0$ for all finitely generated ideals $\mathfrak{a} \subset A$ implies that $\operatorname{Tor}_1(M,A/\mathfrak{a})$ for all ideals $\mathfrak{a} \subset A$. Let's suppose we have such an ideal $\mathfrak{a}$. The trick is to 'approximate' $\mathfrak{a}$ by finitely generated ideals by writing it as an inductive limit $\mathfrak{a} = \varinjlim \mathfrak{a}_n$ of finitely generated ideals (this can always be done). Then, assuming I haven't convinced myself of anything false, we can write $\operatorname{Tor}_1(M,A/\mathfrak{a}) = \operatorname{Tor}_1(M,A/\varinjlim \mathfrak{a}_n) = \operatorname{Tor}_1(M,\varinjlim A/\mathfrak{a}_n) = \varinjlim \operatorname{Tor}_1(M,A/\mathfrak{a}_n)$, thus reducing the question to the finitely generated case. Now you can use the assumption that each $\operatorname{Tor}_1(M,A/\mathfrak{a}_n)$ vanishes.
(disclaimer: I haven't thought hard about commutative algebra for a while, so apologies if I've overlooked anything important)