with t1 as (
select 1 as bindid,1 as a1
union all
select 1 as bindid,2 as a1
),
t2 as (
select 1 as bindid,1 as a2
union all
select 1 as bindid,2 as a2
union all
select 1 as bindid,3 as a2
)
select t2.bindid,t1.a1,t2.a2 from t2 left join t1 on t1.bindid=t2.bindid and a1=a2