Let $X$ be a scheme (e.g. of finite type over $\mathbb C$, but it does not matter) and let $Z\subset X$ be an irreducible component of $X$. Suppose we have an open subscheme $U\subset Z$.
How to characterize when $U$ will still be open in $X$?
The answer is always if the irreducible components are the connected components of $X$, which happens for regular schemes. If two irreducible components meet (hence $X$ is not regular), I did some examples (so I know the answer is not always), but still I cannot figure out a pattern. However, I feel this should be well established.
Thanks for any help.