'How to write flexibleSearch query in hybris HAC for one too many relation?

enter image description hereThis one doesn't work: SELECT *FROM {User as u JOIN Address as a ON {u:a} = {a:pk}} .



Solution 1:[1]

As you see in the relation cardinality is on the owner as User.

so query should be like this

SELECT *FROM {User as u JOIN Address as a ON {u:pk} = {a:owner}} 

Solution 2:[2]

Missed that qualifier is "owner" , usually by convention it is named as a type . select {a.PK} from {customer as c join address as a on {c.pk}={a.owner}}

Solution 3:[3]

Can try this:

 select * from {User as u JOIN Address as a on {u.pk}={a.owner}}

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Raushan Kumar
Solution 2 Roman Lototskyi
Solution 3 ouflak