Furthermore, naming conventions in rails/ruby say you should not have
a variable called tmp, temp, temporary, or any of that ambiguous
naming.

Also, now that you know you should be casting to_i from params, try
using the original method I suggested

@albums = Album.find(:all, :conditions => "where artist_id = '#{params
[:find_id].to_i}'")

and let me know if that solved the issue. It's really bad/wasteful to
pull down all of your artists. Also, shorthand

@collection = Model.find(:all) is the same as @collection = Model.all

likewise, you can do Model.first and Model.last to get the first and
low entry of a table!

Good luck.

On May 23, 1:24 pm, Mk 27 <rails-mailing-l...@andreas-s.net> wrote:
> Hassan Schroeder wrote:
> > Nope, nothing to do with Ruby -- HTTP request parameters are
> > *always* strings.
>
> That makes sense.
>
> Thanks much everyone!
>
> --
> Posted viahttp://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to