I have problems with default values. I don't know whether I'm stupid or doc is not good (you're not supposed to answer ) but I spend a lot of time for trivial things.
According to Wiki RailsBestPractices, it's a good idea to add a default value like that:
When I try to add a default value, I get an error:
def self.custom_find( id_to_find = 1 )
[edit: the query is ok without = 0 default value ]
parse error, unexpected ')', expecting '='
def self.find_query(category, type, city_id, price_min = 0, price_max)
sql conditions coming here...)
Did I miss something?