Wednesday, November 6, 2013

Rails - ActiveRecord query to check for Null value

http://stackoverflow.com/questions/15590827/activerecord-query-w-check-for-empty-field
Review.where("status = ?", status).where("review <> '' AND review IS NOT NULL")

No comments:

Post a Comment

Followers

Blog Archive