Factoring a morphism of schemes when the image is contained in an open subset

206 Views Asked by At

Let $f: X \to Y$ be a morphism of schemes. Suppose $f(X) \subseteq U$, where $U$ is an open subset of $Y$. Is it then the case that $f$ factors as $X \to U \to Y$, where $U \to Y$ is an open immersion? Thank you.