表1
id
1
2
3
--
表2
name
a
b
c
--
输出
id name
1 a
1 b
1 c
2 a
2 b
2 c
3 a
3 b
3 c
(用的dateworks,用odps sql尝试了cross join,不支持没有where限制的
表1
id
1
2
3
--
表2
name
a
b
c
--
输出
id name
1 a
1 b
1 c
2 a
2 b
2 c
3 a
3 b
3 c
(用的dateworks,用odps sql尝试了cross join,不支持没有where限制的
select * from (select *, 1 as tmp from 表1) a join (select *,1 as tmp from 表2) b on a.tmp = b.tmp;