Consider two metric spaces $X,Y$ such as $Y\subseteq X$. Let $A\subseteq Y$. $A$ is open in $Y$ $\iff$ $\exists B\subseteq X$ open in $X$ such that $ A=B\cap Y$
According to this theorem, the set $(\sqrt{2} , \pi) \cap \mathbb Q$ must be open in $\mathbb Q$.
However, as $\sqrt{2}$ and $\pi$ are irrationals, we are excluding boundaries that do not exist in $\mathbb Q$, so I think the set $(\sqrt{2} , \pi) \cap \mathbb Q$ is closed.
The problem is that I see no differences (in terms of openness / closedness) between $(\sqrt{2} , \pi) \cap \mathbb Q$ and $[\sqrt{2} , \pi] \cap \mathbb Q$. Could it be that they are both open and closed ?