Forum: Ruby on Rails 'requests' is a bad table name

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Thomas W. (Guest)
on 2006-02-26 01:31
(Received via mailing list)
... pretty obvious, isn't it? Because you end up with a Request model
and
hence @request instance variables - and there you go: marvellous clash
with
the controller environment that is established in instance variables ...
such
as @request. After renaming my model to 'Inquiry' everything just worked
fine.

Stupid as I am, that insight took me some time to figure out, so I
thought I
could post a warning here.

So that would mean that these are bad model/table names:
- Request/requests
- Param/params
- Cookie/cookies
- Response/responses
- Session/sessions (watch out you conference management coders ;-)
- Header/headers

I couldn't find any hints about reserved model names in the Rails book,
but
only now found this wiki page:

http://wiki.rubyonrails.com/rails/pages/ReservedWords

Hope that helps others from struggling - and please correct if I am
wrong

Thanks
Thomas
This topic is locked and can not be replied to.