Dear all,
Model.column_names gives all the fields in the table.
But it doesnot show the associated fields value.
my model is associated with has_and_belongs_to_many :groups
how can i get the associated fields also…
Any helps …
Thank you
Dear all,
Model.column_names gives all the fields in the table.
But it doesnot show the associated fields value.
my model is associated with has_and_belongs_to_many :groups
how can i get the associated fields also…
Any helps …
Thank you
On Feb 12, 1:12 pm, Newb N. [email protected] wrote:
Any helps …
Thank you
Posted viahttp://www.ruby-forum.com/.
You can get all the associations via reflections:
Model.reflect_on_all_associations
HTH
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs