Although it's not currently possible to use a dynamic link instead of a hardcoded link within a banner promotion while using the Magento "Query Merchandiser", when using the "All Store Views" option for example, it is possible to only specify the path in this URL field. This gives some flexibility with the target link if used strategically.
If the path is the same but on 2 domains https://d1.com/path and https://d2.com/path, you can specify only /path in the URL field so it will stay on the current website domain (although the URL will open in a new tab/window).