It's a crazy situation, but I often find myself in uncharted space, so nothing new here. 8-)

I need to have 1 relation editable field point out to pages in many templates. Normal relation allows single masterpage only.
I decided to solve this by relating editable field to the same masterpage it is defined in. Subsequently, if I need page X to relate to page A in masterpage MA.php, I create a `proxy` page Z holding data about that page MA.php->A and relate X to Z. If I need to relate X to page B in masterpage MB.php I create a `proxy` page Y holding data (id, name, etc) about page B of MB.php and relate X to Y.

This solution is extremely rare to be used, and will mostly be used programmatically but nevertheless is effective in terms of database requests. Only one extra request is needed to find information about the target page. Just by asking data which the proxy page knows. Any numer of masterpages and pages can be related to, programmatically without setting a ton of `fixed` editable fields.

(instead of relating to self, there can be a separate `service` masterpage which will have copies of info of pages from other masterpages that are to be related to)