HABTM pregunta

I have 2 habtm relations:

FORM <- HABTM-> COMPANIES
FORM <- HABTM -> SITES

Is there an easy way to do a query like:

Find out what sites belong to what company related to the form?

Also is there a better or more efficient way of setting this kind of
scenario up?

The FORM can have multiple companies associated as well as multiple
sites belonging to each company.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs