problems getting a particular version

I am running on windows and try the following command to no avail: gem install rails --version 2.2.2

and I get back:

ERROR: could not find rails locally or in a repository.

Why do I get this error? How do I fix it?