  Let $p$ be a prime, let $1 \le t < d < p$ be integers, and let $S$ be a
non-empty subset of $\mathbb{F}_p$. We establish that if a polynomial
$P:\mathbb{F}_p^n \to \mathbb{F}_p$ with degree $d$ is such that the image
$P(S^n)$ does not contain the full image $A(\mathbb{F}_p)$ of any non-constant
polynomial $A: \mathbb{F}_p \to \mathbb{F}_p$ with degree at most $t$, then $P$
coincides on $S^n$ with a polynomial that in particular has bounded
degree-$\lfloor d/(t+1) \rfloor$-rank in the sense of Green and Tao. Similarly,
we prove that if the assumption holds even for $t=d$, then $P$ coincides on
$S^n$ with a polynomial determined by a bounded number of coordinates.
