Remove VARCHAR & refactor into case statement.

I'm not sure how to run the specs locally, where should I look for the database setup?