mdx高手帮忙,microstrategy 很容易实现,但as里有点没头绪
column date store col1 col2
20080101 a1 1 1
20080101 b1 1 1
20080102 a1 0 1
20080102 b1 1 1
要实现 sum((sum(ytd() ,col1) by store ) / (sum(ytd() ,col2) by store) )
即按每store去 计算YTD()的 col1和col2的值,然后在求和
如 a1 (1+1)/(1+1)=1 a1的店 ytd() co1 的值 / a1店 ytd() col2
b1 (1+0)/(1+1)=0.5 b1的店 ytd() co1 的值 / b1店 ytd() col2
..................
最终把all store的值求和 1+0.5=1.05
各位有什么好的思路,在线等待或给我mail
xbinwu@163.com thanks