If $F=P/Q$ is integral infinitely often then $F$ is a polynomial.
Write $$P(x)=f(x)Q(x)+R(x)$$ for some polynomial $R$ of degree strictly less than the degree of $Q$. If you have infinitely many integral $x$ so that $P/Q$ is integral then you get infinitely many $x$ so that $NR/Q$ is integral, where $N$ is the product of all denominators of the coefficients in $f$. However $R/Q\to 0$ as $x\to \pm \infty$ so $R\equiv 0$ and so $Q(x)$ is a divisor of $P(x)$.
Now, as pointed out by Mark Sapir below, not all polynomials with rational coefficients take on integer values infinitely often (at integers), but you can check this in all practical cases by seeing if $F$ dF$has a root$\pmod{d}$, where$d$is the common denominator of the coefficients in$F$. 3 added 307 characters in body Only when the rational function If$F=P/Q$is itself integral infinitely often then$F$is a polynomial!. Write $$P(x)=f(x)Q(x)+R(x)$$ for some polynomial$R$of degree strictly less than the degree of$Q$. If you have infinitely many integral$x$so that$P/Q$is integral then you get infinitely many$x$so that$NR/Q$is integral, where$N$is the product of all denominators of the coefficients in$f$. However$R/Q\to 0$as$x\to \pm \infty$so$R\equiv 0$and so$Q(x)$is a divisor of$P(x)$. Now, as pointed out by Mark Sapir below, not all polynomials with rational coefficients take on integer values infinitely often (at integers), but you can check this in all practical cases by seeing if$F$has a root$\pmod{d}$, where$d$is the common denominator of the coefficients in$F$. 2 added 74 characters in body Only when the rational function is itself a polynomial! Write $$P(x)=f(x)Q(x)+R(x)$$ for some polynomial$R$of degree strictly less than the degree of$Q$. If you have infinitely many integral$x$so that$P/Q$is integral then you get infinitely many$x$so that$R/Q$NR/Q$ is integral. , where $N$ is the product of all denominators of the coefficients in $f$. However $R/Q\to 0$ as $x\to \pm \infty$ so $R\equiv 0$ and so $Q(x)$ is a divisor of $P(x)$.