WITH MEMBER [measures].[calc] AS ' [measures].[actual_max]-[measures].[actual_min]' MEMBER [time].[agg complexfunc] AS 'aggregate([time].[all time].[1994].children)' SELECT {[time].[all time].[1994].children, [time].[agg complexfunc]} ON 0, {measures].[actual_max], [measures].[actual_min], [measures].[actual_sum], [masures].[actual_n], [measures].[actual_avg], measures.calc} on 1 FROM [prdmddb]This example returns the following:
1 2 3 4 agg complexfunc actual_max $1,000.00 $987.00 $992.00 $1,000.00 $1,000.00 actual_min $13.00 $3.00 $20.00 $15.00 $3.00 actual_sum $89,763.00 $93,359.00 $89,049.00 $88,689.00 $360,860.00 actual_n 180 180 180 180 720 actual_avg $498.68 $518.66 $494.72 $492.72 $501.19 calc 987 984 972 985 997
WITH MEMBER [time].[agg complexfunc] AS 'aggregate([time].[all time].[1994].children, measures.actual_max + 1)' SELECT {[time].[all time].[1994].children, [time].[agg complexfunc]} ON 0, {[measures].[actual_max], [measures].[actual_min], [measures].[actual_sum], [measures].[actual_n], [measures].[actual_avg]} on 1 FROM [prdmddb]This example returns the following:
1 2 3 4 agg complexfunc actual_max $1,000.00 $987.00 $992.00 $1,000.00 $1,001.00 actual_min $13.00 $3.00 $20.00 $15.00 $988.00 actual_sum $89,763.00 $93,359.00 $89,049.00 $88,689.00 $3,983.00 actual_n 180 180 180 180 3983 actual_avg $498.68 $518.66 $494.72 $492.72
WITH MEMBER [time].[agg complexfunc] AS 'aggregate([time].[all time].[1994].children, measures.actual_max - measures.actual_min)' SELECT {[time].[all time].[1994].children, [time].[agg complexfunc]} ON 0, {[measures].[actual_max], [measures].[actual_min], [measures].[actual_sum], [measures].[actual_n], [measures].[actual_avg]} on 1 FROM [prdmddb]This example returns the following:
1 2 3 4 agg complexfunc actual_max $1,000.00 $987.00 $992.00 $1,000.00 $987.00 actual_min $13.00 $3.00 $20.00 $15.00 $972.00 actual_sum $89,763.00 $93,359.00 $89,049.00 $88,689.00 $3,928.00 actual_n 180 180 180 180 3928 actual_avg $498.68 $518.66 $494.72 $492.72
WITH MEMBER [measures].[agg complexfunc] AS 'aggregate([time].[all time].[1994].children, measures.actual_avg)' SELECT {[measures].[actual_sum], [measures].[actual_n], [measures].[agg complexfunc]}ON 0, {[time].[all time].[1994].children} ON 1 FROM [prdmddb]This example returns the following:
actual_sum actual_n agg complexfunc 1 $89,763.00 180 501.194444444444 2 $93,359.00 180 501.194444444444 3 $89,049.00 180 501.194444444444 4 $88,689.00 180 501.194444444444
WITH MEMBER [measures].agg complexfunc] AS 'aggregate([time].[all time].[1994].children, measures.actual_avg + 12)' SELECT {[measures].[actual_sum], [measures].[actual_n], [measures].[agg complexfunc]} ON 0, {[time].[all time].[1994].children} ON 1 FROM [prdmddb]This example returns the following:
actual_sum actual_n agg complexfunc 1 $89,763.00 180 2 $93,359.00 180 3 $89,049.00 180 4 $88,689.00 180
WITH MEMBER [measures].[agg complexfunc] AS 'aggregate([time].[all time].[1994].children, measures.actual_max + 12)' SELECT {[measures].[actual_max], [measures].[agg complexfunc]} ON 0, {[time].[all time].[1994].children} ON 1 FROM [prdmddb]This example returns the following:
actual_max agg complexfunc 1 $1,000.00 1012 2 $987.00 1012 3 $992.00 1012 4 $1,000.00 1012
WITH MEMBER [measures].[agg complexfunc] AS 'aggregate([time].[all time].[1994].children, measures.actual_max + measures.actual_min)' SELECT {[measures].[actual_max], measures.actual_min, [measures].[agg complexfunc]} ON 0, {[time].[all time].[1994].children} ON 1 FROM [prdmddb]This example returns the following:
actual_max actual_min agg complexfunc 1 $1,000.00 $13.00 2 $987.00 $3.00 3 $992.00 $20.00 4 $1,000.00 $15.00