Error Messag: A table of multiple values was supplied where a single value was expected.

ilovasen

New Member
Joined
Jun 10, 2013
Messages
16
Hi

I am trying to use make a pivottable per month and year based on the formulas below.

Gross Sales USD:=CALCULATE(sum(factFin[AmountUSD]), ALL( DateTable), FILTER( DateTable, DateTable[MonthOfYear] = VALUES( DateTable[MonthOfYear])), FILTER(ALL(CoA),CoA[AccSum2] = "398X"))

Gross Sales GWh:=CALCULATE(sum(factFin[belopp]), FILTER( DateTable, DateTable[MonthOfYear] = VALUES( DateTable[MonthOfYear])), FILTER(CoA,CoA[AccSum2] = "E-SOLD-SUM"))

Monomic Price Cent Per kWh:=DIVIDE(([Gross Sales USD]*1000*100),([Gross Sales GWh]*1000000),BLANK())

I am able to get the individual results if I select a month from a Timeline slicer. Why should the error message show up and how can i solve it.

Any suggestions?

brgds,
Inge
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
Problem solved by removing , FILTER( DateTable, DateTable[MonthOfYear] = VALUES( DateTable[MonthOfYear]))

Brgds, Inge
 
Upvote 0
Likely what is happening is that on the Grand Total cell, you have multiple MonthOfYear, so the VALUES() function gets grumpy. You can prevent that by wrapping your measure in IF (HASONEVALUE(DateTable[MonthOfYear]), ...)
 
Upvote 0

Forum statistics

Threads
1,224,034
Messages
6,176,001
Members
452,695
Latest member
Alhassan

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top