  Let $K$ be any field and $G$ be a finite group. Let $G$ act on the rational
function field $K(x_g:g\in G)$ by $K$-automorphisms defined by $g\cdot
x_h=x_{gh}$ for any $g,h\in G$. Noether's problem asks whether the fixed field
$K(G)=K(x_g:g\in G)^G$ is rational (=purely transcendental) over $K$. We will
prove that if $G$ is a non-abelian $p$-group of order $p^n$ ($n\ge 3$)
containing a cyclic subgroup of index $p^2$ and $K$ is any field containing a
primitive $p^{n-2}$-th root of unity, then $K(G)$ is rational over $K$. As a
corollary, if $G$ is a non-abelian $p$-group of order $p^3$ and $K$ is a field
containing a primitive $p$-th root of unity, then $K(G)$ is rational.
