-
Notifications
You must be signed in to change notification settings - Fork 43
Open
Description
I've run into this a few times now. Using Repo.get with a query passed to it ignores everything about the query except for the preloads. For example:
Repo.get(Session, session_id, Query.where(valid: "true"))Generates a query like:
SELECT * FROM acc_sessions WHERE key='...' LIMIT 1Where the valid = "true" has not been added to the query string.
Reading the docs for Repo.get, it looks like that is intentional, but it seems rather limiting and unintuitive to me. Like in the example above, I'd like to be able to use that query parameter as a way of filtering out results that I'm not interested in, rather than having to use Repo.all(...).first.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels