id 新闻 对应新闻
1 A B
2 A C
3 A D
4 B E
5 B F
6 B Gselect 新闻 from tablename where 对应新闻= 'B'
union
select 对应新闻 from tablename where 新闻= 'B'
1 A B
2 A C
3 A D
4 B E
5 B F
6 B Gselect 新闻 from tablename where 对应新闻= 'B'
union
select 对应新闻 from tablename where 新闻= 'B'
A B
A C
A D
B E
B F
B Gselect content from tb where id = 'B'
union all
select id as content from tb where content = 'B'
1 A B
2 A C
3 A D
4 B E
5 B F
6 B Gselect 新闻 from tablename where 对应新闻= 'B'
union
select 对应新闻 from tablename where 新闻= 'B'
---------------------
除了查询连接还有没有其他更好的解决方案?