Opened 5 years ago

Closed 4 years ago

Last modified 4 years ago

#31122 closed Cleanup/optimization (fixed)

Clarify how the Lookup class follow the Query Expression API.

Reported by: Hongtao Ma Owned by: Caio Ariede
Component: Documentation Version: 3.0
Severity: Normal Keywords:
Cc: AP Jama Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

For a class to be a lookup, it must follow the Query Expression API. **Lookup and Transform naturally follow this API.**
A Lookup is a generic class to implement lookups. A lookup is a query expression with a left-hand side, lhs; a right-hand side, rhs; and a lookup_name that is used to produce a boolean comparison between lhs and rhs such as lhs in rhs or lhs > rhs.

The notation to use a lookup in an expression is <lhs>__<lookup_name>=<rhs>.

**This class doesn’t follow the Query Expression API** since it has =<rhs> on its construction: lookups are always the end of a lookup expression.

Change History (10)

comment:1 by Mariusz Felisiak, 5 years ago

Summary: Contradiction in docs/ref/models/lookupsClarify how `Lookup` follow the Query Expression API.
Triage Stage: UnreviewedAccepted

Agreed, we should clarify how the Lookup class follow the Query Expression API, because it implements as_sql() and as_vendorname().

comment:2 by Mariusz Felisiak, 5 years ago

Summary: Clarify how `Lookup` follow the Query Expression API.Clarify how the Lookup class follow the Query Expression API.

comment:3 by AP Jama, 4 years ago

Owner: changed from nobody to AP Jama
Status: newassigned

comment:4 by AP Jama, 4 years ago

Cc: AP Jama added
Owner: AP Jama removed
Status: assignednew

comment:5 by Caio Ariede, 4 years ago

Owner: set to Caio Ariede
Status: newassigned

comment:6 by Caio Ariede, 4 years ago

Has patch: set

comment:7 by Mariusz Felisiak, 4 years ago

Patch needs improvement: set

comment:8 by Mariusz Felisiak, 4 years ago

Patch needs improvement: unset
Triage Stage: AcceptedReady for checkin

comment:9 by Mariusz Felisiak <felisiak.mariusz@…>, 4 years ago

Resolution: fixed
Status: assignedclosed

In 9a3454f:

Fixed #31122 -- Clarified that Lookup acts as a query expression.

comment:10 by Mariusz Felisiak <felisiak.mariusz@…>, 4 years ago

In 7ace6265:

[3.1.x] Fixed #31122 -- Clarified that Lookup acts as a query expression.

Backport of 9a3454f6046b9b7591fd03e21cf6da0b23c57689 from master

Note: See TracTickets for help on using tickets.
Back to Top