From: James Coglan Date: 2008-09-23T20:57:00+09:00 Subject: Re: Optionally pass a parameter? ------=_Part_24004_32226648.1222171021586 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline > > some_test ? :conditions => "id=100" : nil Try turning it inside out: :conditions => (some_test ? "id=100" : nil) or: :conditions => (some_test && "id=100") Not too sure about what the second one will cause Rails to do if some_test is false rather than nil, but worth a try. ------=_Part_24004_32226648.1222171021586--