9. (16 points) In the geometric sequence $\left\{a_{n}\right\}$ where all terms are positive, what is the maximum number of terms that can be integers between $100 \sim 1000$?
9. Let the geometric sequence $\left\{a q^{n-1}\right\}$ satisfy
$$
100 \leqslant a q^{n-1} \leqslant 1000 \quad (a, q > 1) \text{ are integers.}
$$
Clearly, $q$ must be a rational number.
Let $q=\frac{t}{s}(t>s \geqslant 1, (t, s)=1)$.
Since $a q^{n-1}=a\left(\frac{t}{s}\right)^{n-1}$ is an integer, $a$ must be a multiple of $s^{n-1}$.
Let $t=s+1$. Thus, the sequence satisfies
$100 \leqslant a < a \cdot \frac{s+1}{s} < \cdots < a\left(\frac{s+1}{s}\right)^{n-1} \leqslant 1000$.
If $s \geqslant 3$, then
$1000 \geqslant a\left(\frac{s+1}{s}\right)^{n-1} \geqslant (s+1)^{n-1} \geqslant 4^{n-1}$.
Thus, $n \leqslant 5$.
If $s=1$, then
$1000 \geqslant a \cdot 2^{n-1} \geqslant 100 \times 2^{n-1}$.
Thus, $n \leqslant 4$.
If $s=2$, then
$1000 \geqslant a\left(\frac{3}{2}\right)^{n-1} \geqslant 100\left(\frac{3}{2}\right)^{n-1}$.
Thus, $n \leqslant 6$.
On the other hand, the sequence
$128, 192, 288, 432, 648, 972$

satisfies the given conditions.
Therefore, the maximum number of terms between 100 and 1000 is 6.