Hi, I am having an issue with query below providing inconsistent results depending on the order the measures are placed in the select or if there are multiple levels of the same hierarchy selected in the where.
SELECT
{
[Measures].[Disconnects],-- Measure Group 1 loaded
[Measures].[Beginning Active Balance], --calc'd measure
[Measures].[Ending Active Balance],-- calc'd measure [Measures].[Beginning Active Balance] + [Measures].[Net Connects]
[Measures].[Net Connects]-- Measure Group 1 loaded
} on rows,
{
[DimPeriod].[Calendar].[Month].&[January 2013],
[DimPeriod].[Calendar].[Month].&[February 2013]
}
on columns
FROM
Cube
WHERE
{
[DimCustomerRegion].[Customer Region].[Regionlevel02].&[-1754023157],
[DimCustomerRegion].[Customer Region].[Regionlevel03].&[-2.027620909E9],
[DimCustomerRegion].[Customer Region].[Regionlevel03].&[-1.78883323E9],
[DimCustomerRegion].[Customer Region].[Regionlevel03].&[1.59852332E8]
}
the results of this is
January 2013 February 2013
Disconnects2884125656
Beginning Active Balance18063751769506
Ending Active Balance18063751769506
Net Connects(null)(null)
The Net connects for this period is NULL which is not correct. If I change the select to be
SELECT
{
[Measures].[Beginning Active Balance],
[Measures].[Ending Active Balance],
[Measures].[Disconnects]
[Measures].[Net Connects],
} on rows,
I get the right result which shows a value for Net Connects and a valid Ending amount.
January 2013 February 2013
Beginning Active Balance18063751769506
Ending Active Balance17695061772032
Net Connects-368692526
Disconnects2884125656
I also noticed that if I change the where clause to remove the level2 member it works fine (valid Net and Ending). Can anybody point me in the right direction as to why this is occurring? Thanks in advance.
SELECT
{
[Measures].[Disconnects],-- Measure Group 1 loaded
[Measures].[Beginning Active Balance], --calc'd measure
[Measures].[Ending Active Balance],-- calc'd measure [Measures].[Beginning Active Balance] + [Measures].[Net Connects]
[Measures].[Net Connects]-- Measure Group 1 loaded
} on rows,
{
[DimPeriod].[Calendar].[Month].&[January 2013],
[DimPeriod].[Calendar].[Month].&[February 2013]
}
on columns
FROM
Cube
WHERE
{
[DimCustomerRegion].[Customer Region].[Regionlevel02].&[-1754023157],
[DimCustomerRegion].[Customer Region].[Regionlevel03].&[-2.027620909E9],
[DimCustomerRegion].[Customer Region].[Regionlevel03].&[-1.78883323E9],
[DimCustomerRegion].[Customer Region].[Regionlevel03].&[1.59852332E8]
}
the results of this is
January 2013 February 2013
Disconnects2884125656
Beginning Active Balance18063751769506
Ending Active Balance18063751769506
Net Connects(null)(null)
The Net connects for this period is NULL which is not correct. If I change the select to be
SELECT
{
[Measures].[Beginning Active Balance],
[Measures].[Ending Active Balance],
[Measures].[Disconnects]
[Measures].[Net Connects],
} on rows,
I get the right result which shows a value for Net Connects and a valid Ending amount.
January 2013 February 2013
Beginning Active Balance18063751769506
Ending Active Balance17695061772032
Net Connects-368692526
Disconnects2884125656
I also noticed that if I change the where clause to remove the level2 member it works fine (valid Net and Ending). Can anybody point me in the right direction as to why this is occurring? Thanks in advance.