BIEE11G创建分析的表格如何实现行列转化?!!
0
需要展示的原始数据格外为流水式,fir_inv_month、source两个为列维度,v_month为自然月份,lc_users_nums、avg_lc_ab1000_asset为数据指标。
现在需要展示位: fir_inv_month,sourec,数据指标,month1,month2....month12(12月)
eg1: 201501,ct0006,lc_users_nums,1,0,0,0,0,0,0,0,0,0,1,0 (追踪15年12个月)
201501,ct0060,avg_lc_ab1000_asset,10000,0,0,0,0,0,0,0,0,0,0,0
201601,ct0006,lc_users_nums,1,0,0,0,0,0,0,0,0,0,1,0 (追踪16年12个月)
201601,ct0060,avg_lc_ab1000_asset,10000,0,0,0,0,0,0,0,0,0,0,0
请问,在不对原数据做修改的情况下,如何利用BIEE的行列转化功能实现上面的效果
现在需要展示位: fir_inv_month,sourec,数据指标,month1,month2....month12(12月)
eg1: 201501,ct0006,lc_users_nums,1,0,0,0,0,0,0,0,0,0,1,0 (追踪15年12个月)
201501,ct0060,avg_lc_ab1000_asset,10000,0,0,0,0,0,0,0,0,0,0,0
201601,ct0006,lc_users_nums,1,0,0,0,0,0,0,0,0,0,1,0 (追踪16年12个月)
201601,ct0060,avg_lc_ab1000_asset,10000,0,0,0,0,0,0,0,0,0,0,0
请问,在不对原数据做修改的情况下,如何利用BIEE的行列转化功能实现上面的效果
没有找到相关结果
重要提示:提问者不能发表回复,可以通过评论与回答者沟通,沟通后可以通过编辑功能完善问题描述,以便后续其他人能够更容易理解问题.
1 个回复
langrenwanghu 2017-02-21 回答
赞同来自:
oracle中的pivot函数
pivot
( ---行列转置
max(lc_user_nums) lc_user_nums ,max(avg_ab1000_asset) avg_ab1000_asset
for v_month in (201701 Month1,201702 Month2,201703 Month3,201704 Month4,201705 Month5,201706 Month6
,201707 Month7,201708 Month8,201709 Month9,201710 Month10,201711 Month11,201712 Month12)
)