Forum Discussion
error with VALUES
- 8 years ago
Hi Lexey,
The issue here is your aggregation level, using the all fact table to make your percentage when you add several columns from your table it will give you the total cost divided by all the slice and dices so not 100% per column. Because you are making it at a Jobs level you need to calculated it at that level so you need to change your percentage to:
Procentage = CALCULATE([total cost] / CALCULATE([total cost]; ALL('fact'[jobs])))Other issue is Budget value you are making a sumX of the plan and then multiplying that sumx by the porcentage on SUMX the calculations are made line by line and then summed so you need to calculate for each cost line the percentage value and then do the sum you need to change it to:
Values of budget = SUMX(plan;plan[plan] * [Procentage])
See result am PBIX file below:
Regards,
MFelix
Коллегам, Даксеру нужна помощь!
есть таблица с работами и стоимость http://prntscr.com/j5mbxu для каждого здания
Существует запланированный бюджет, я делаю небольшой анализ распределения текущих расходов, и я пытаюсь навязать его по плану, но если в фильтре я выбираю один объект, все в порядке, если два
Сообщение об ошибке:
MdxScript (модель) (13, 50) Ошибка вычисления в измерении 'Management_Timesheets' [Значения бюджета]: была представлена таблица с несколькими значениями, где ожидалось одно значение.
формулу, которая распределяет проценты:
Значения бюджета = VALUES (Management_Timesheets [Сумма контракта (EUR)]) * [Процент]
Процент = [Honorar] / РАСЧЕТ ([Honorar]; ALLSELECTED (Management_Timesheets))
Попросить помощи!