我想知道是否有一种方法可以在查询的一列中获取子查询的多个结果......像这样:
otherid | resultsFromsomeData
1 | 1,2,3
2 | 1,5
3 | No Data
我正在尝试这样的事情:
select o.otherID,
CASE WHEN (select otherID from someData where someid=o.otherID)>1 THEN
''||(select otherID from someData where someid=o.otherID)||'' /*here I am*/
WHEN (select otherID from someData where someid=o.otherID)<1 THEN
'No Data'
END
as resultsFromsomeData
from OtherData o