oracle 列转行逗号分隔

-- oracle 列转行逗号分隔
select 
    year,
    listagg(sales_amount, ',') within group (order by sales_amount) as sales_amounts
from sales_data
group by year

 

posted @ 2024-12-05 14:06  一隅桥畔  阅读(61)  评论(0)    收藏  举报