Riemann Lebesgue lemma on $L^2(\mathbb{R})$ I am trying to understand why the Riemann Lebesgue lemma does not hold on $L^2(\mathbb{R})$.
I have looked at the answers given on a similar question on mathstackexchange (see here), but I do not understand why $\hat{f}$ cant be defined pointwise in $L^2$.
I have seen in class that for $f \in L^2(\mathbb{R})$, we have
$\hat{f}(\xi)=\lim_{R\rightarrow \infty} \int_{-R}^R f(x) e^{-2 \pi ix \xi}dx$
Why is this not defined pointwise?
Please do not mark as duplicate.I have already seen the other posts but I do not understand them.

The formula you wrote holds almost everywhere, but that's a specialized result, and likely not what was written in class. The limit in your formula is easily seen to exist in the  norm topology from $L^2$, so it is not a pointwise limit. 
In other words, for each $R$ define the function $f_R$ by 
$$
f_R(\xi)=\int_{-R}^R f(x) e^{-2\pi i x\xi}\,dx
$$
(the notation here is already not ideal, because this is a Lebesgue integral). Then, what was shown in your class is that
$$\tag1
\hat f=\lim_{R\to\infty} f_R, 
$$
in the sense that 
$$
\lim_{R\to\infty} \|\hat f-f_R\|_2=0.
$$
The transform $\hat f$ makes sense because of the Plancherel Theorem, which says that the map $f\longmapsto \hat f$ (for those function $L^2$ such that it is defined) is an isometry in $\|\cdot\|_2$. Then one uses the density of a dense subset of $L^1(\mathbb R)$ in $L^2(\mathbb R)$ (like the compactly supported continuous functions) to extend the Fourier transform by density, which is what $(1)$ says. 
