Use query.get() to access objects by PK
Registered by
Dolph Mathews
From the SqlAlchemy docs:
"get() is special in that it provides direct access to the identity map of the owning Session. If the given primary key identifier is present in the local identity map, the object is returned directly from this collection and no SQL is emitted, unless the object has been marked fully expired. If not present, a SELECT is performed in order to locate the object."
Source: http://
Related havana summit etherpad: https:/
Blueprint information
- Status:
- Complete
- Approver:
- Dolph Mathews
- Priority:
- Low
- Drafter:
- Dolph Mathews
- Direction:
- Approved
- Assignee:
- Dolph Mathews
- Definition:
- Approved
- Series goal:
- Accepted for havana
- Implementation:
- Implemented
- Milestone target:
- 2013.2
- Started by
- Dolph Mathews
- Completed by
- Dolph Mathews
Related branches
Related bugs
Sprints
Whiteboard
Gerrit topic: https:/
Addressed by: https:/
get SQL refs from session (bp sql-query-get)
(?)