Hi,

I've 2 tables
1. Users
2. StatusMessages

@user = Users.find(1)
@status = @user.status_messages

with these lines I'm getting the record of users and status_messages table.
here I can refer in @status with @user.id for status messages of each user.
in this I want to check this for each user in my code.

is there any way to get the data - username(from Users) and
status_message(from StatusMessage) in a single variable.
ie I want to access like:
*@userstatus.username
@userstatus.status_message*

I'm using rails 3.1

Thank you,
Sayuj

-- 
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 [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to