Error: Does not select column of table additional store

Jmix version 1.5
I use 2 datastores
Table “A” (entity “lc_A”): Main data store
Table “Bank” (entity “cmn_Bank”): Additional data store
“lc_A” many to one “cmn_Bank”
Tag entity “lc_A” I’ve added :
fetchPlan extends="_base"
property name=“bank”
fetchPlan
ảnh
ảnh
ảnh
ảnh

When executing the select statement by “bank.name”, I get the error:
Caused by: org.eclipse.persistence.exceptions.JPQLException:
Exception Description: Problem compiling [select e from lc_A e where (e.status is not null) and ((lower ( e.code) like :codesqQwWBGy or lower ( e.bank.name) like :bank_nameYqKrkhVa)) order by e.createdDate desc].
The state field path ‘e.bank.name’ cannot be resolved to a valid type.
How do I resolve the above error?

Hi,

You can’t use fields that belong to the referenced entity from additional datastore in the query for the main entity.