Let $Y \subset X$ noetherian schemes, $\mathcal{F} \in Y-\mathbf{Mod}$. When $H^i(Y,\mathcal{F})=H^i(X,\mathcal{F})?$ Is it true in general? Is it true in case when $\mathcal{F}$ coherent? The question emerged because Hartshorne proof of III.7.4:
I think he uses fact $H^{N-i}(P,\mathcal{O}_X(-q))=H^{N-i}(X,\mathcal{O}_X(-q))$. But for me its not obvious why its true.
