Validating field uniqueness via Ajax call with appropriate message in Rails 3

Hello all,

I am trying to do a Rails + AJAX call validation to check for the
uniqueness of a field, by crawling the back end DB and return an
appropriate message based on the result.

I am on Rails 3.0.11.

Your kind inputs on what could be the best way to tackle this would be
of real help.

Is there a ruby gem / js plugin / jquery plugin that I can make use of?

Any blogs links implementing the same would also be handy..

Thank you.