Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New page/section for "Querying by associations" #533

Closed
mltsy opened this issue Jul 21, 2023 · 3 comments
Closed

New page/section for "Querying by associations" #533

mltsy opened this issue Jul 21, 2023 · 3 comments

Comments

@mltsy
Copy link

mltsy commented Jul 21, 2023

Issue Description

I searched and experimented for hours before discovering the "nested column syntax" for including a where clause from a nested/joined table. It was hard to find because it's in the section about eager loading (which is not at all related to what I was trying to do - I don't even need the related data returned, I just needed to filter by it).

I admit this was partly due to my laziness (AKA lack of interest in reading through pages of docs that were not related to what I needed to know), because I did find the "Eager Loading" page fairly early on, but backed out of it as most of it seemed to be focused on how to include or not include data from the associated models (i.e. eager loading!), and the part I needed (which is not actually strictly related to eager loading) was buried somewhere in the middle.

What was unclear/insufficient/not covered in the documentation

The concepts were covered very well, but not discoverable for me, being nested under "Eager Loading"

If possible: Provide some suggestion on how we can enhance the docs

I have two simple ideas (either of which would improve discoverability IMO):

  1. Rename the "Eager Loading" section "Querying with Associations"
    • this better encompasses all that is covered in this section, and while that may sound like it's the same thing as "eager loading", eager loading is only one aspect of Querying with associations
  2. Create a new section for "Filtering by associations" that would include just the sections about filtering queries by joined tables.
@WikiRik
Copy link
Member

WikiRik commented Jul 21, 2023

We've rewritten a big part of the documentation for v7. Does that documentation implement your suggestions in a good enough way?

@mltsy
Copy link
Author

mltsy commented Jul 25, 2023

Oh, sho' nuf does!

### Referencing associated models in a parent WHERE clause

I love it - thank you for pointing this out 😄 🙏 (Were these just published?? I don't know how to tell)

@mltsy mltsy closed this as completed Jul 25, 2023
@ephys
Copy link
Member

ephys commented Jul 26, 2023

Yes, this was released about a month ago (#330)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants