Skip to content

Watch the whitespace

by admin on October 30th, 2009

I have been spending the last hour wondering why this doesnt work.

Post.find_by_sql["SELECT title FROM posts WHERE author = ? AND created > ?", author_id, start_date]

Its because it needed to be like this:
Post.find_by_sql ["SELECT title FROM posts WHERE author = ? AND created > ?", author_id, start_date]

yeah, you need that whitespace there.

No comments yet

Leave a Reply

Note: XHTML is allowed. Your email address will never be published.

Subscribe to this comment feed via RSS