Query by pointer property

Hello,

I wanted to ask a question. Do you know if it is possible somehow or will it be possible to query a class, in which that class has a pointer and a query can be made by a property of the pointer?

Such as making a distinct of $query->distinct(pointerObject.key);

I understand that this is possible in the iOS and android SDKs by some people I know.

Regards.