Example of a non locally-compact space with a dense locally compact subspace.

Let $X$ be a topological space such that $A \subset X$ is a dense subspace which is locally compact and $B \subset X$ is a dense subspace which is not locally compact (at all of its points).

Is it possible to find such $X$? if it is, an example?

• @KevinCarlson you're right, it's not as simple as I thought. – Jonathan Y. Dec 20 '13 at 12:51

There remains some imprecision in how you've worded the question, but here's a non-locally compact space with a locally compact, indeed compact, dense subset. Just take your favorite non-locally compact space $X$ and construct $X'$ by adjoining a generic point $\star$, modifying the topology by adding $\star$ to every open set, including the empty set (of course we must add the empty set back in again!)
Then the closure of $\{\star\}$ is $X'$ but, being finite, $\{\star\}$ is compact. On the other hand, $X'$ still isn't locally compact at any of the points at which $X$ wasn't, because $X$ is closed and closed subspaces of locally compact spaces are locally compact.
1)If $X$ must be Hausdorff, take $X=\mathbb{R}$, $A=X-\{0\}$, $B=\mathbb{Q}$.
2)If $X$ must be a non-locally compact Hausdorff space, let $Y=\{1/n|n\in \mathbb{N}^*\}$ and $X=(\{0\}\times \mathbb{Q}) \cup (Y\times \mathbb{R})$, $X$ is not locally compact at the point $(0,0)$.
Let $A=Y\times \mathbb{R}$, $A$ is dense in $X$ and is locally compact.
Let $B=Y \times \mathbb{Q}$, $B$ is dense in $X$ and $B$ is not locally compact at all of its points.