I have two tables both have a column called host. I would like to join these two tables by some part of host, like below which is working:
select * from `config.tested` a
join `config.active` b
on REGEXP_EXTRACT(a.host, r'.*req-([a-z0-9]{12})')=REGEXP_EXTRACT(b.host, r'.*req-([a-z0-9]{12})')
is there any more efficient way?like USING(REGEXP_EXTRACT(host, r'.*req-([a-z0-9]{12})')) it does not work