#40 new
Xavier Noria

finding and nils

Reported by Xavier Noria | December 23rd, 2007 @ 10:57 AM | in Second Edition

To ponder for section "Advanced Finding/Conditions":

When you write "column = ?" or "column = :foo" you need to be certain the value to test is not nil. Otherwise you'd need to special-case that SQL to generate "column IS NULL" if needed.

Dynamic finders and hashes for :conditions deal with nil values automatically, generating the right SQL syntax out-of-the-box.

Comments and changes to this ticket

Please Login or create a free account to add a new comment.

You can update this ticket by sending an email to from your email client. (help)

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

People watching this ticket