The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hi all,
I am facing a very weird error, please help:
1. I have a Measure that reads the Currency Code called "Project Currency"
2. I am using an If/Switch Statement to check this Currency
3. In regards to what currency it is, I Multiple the exchange rate to a column called "Exp"
4. EXP is NOT a measure
5. I am facing this error : "A table of multiple values was supplied where a sigle value was expected"
6. My code :
Note: I used this before and it worked flawlessly and is still working in my old Dashboard.
Solved! Go to Solution.
Try this
CurCol =
IF( SELECTEDVALUE([Project Currency]) = "AED", 'Union SAP Past/Forecast Exp'[Exp] * 4.2373,
IF( SELECTEDVALUE([Project Currency]) = "QAR", 'Union SAP Past/Forecast Exp'[Exp] * 4.1998,
IF( SELECTEDVALUE([Project Currency]) = "OMR", 'Union SAP Past/Forecast Exp'[Exp] * 0.44363,
IF( SELECTEDVALUE([Project Currency]) = "SAR", 'Union SAP Past/Forecast Exp'[Exp] * 4.32672
)
)
)
)
Regards
Phil
Proud to be a Super User!
Hi, @rf5896
You may try the following measure to see if it works.
CurCol =
switch(
[Project Currency],
"AED",sum('Union SAP Past/Forecast Exp'[Exp])*4.2373,
"QAR",sum('Union SAP Past/Forecast Exp'[Exp])*4.1998,
"OMR",sum('Union SAP Past/Forecast Exp'[Exp])*044363,
"SAR",sum('Union SAP Past/Forecast Exp'[Exp])*4.32672
)
Best Regards
Allan
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @rf5896
You may try the following measure to see if it works.
CurCol =
switch(
[Project Currency],
"AED",sum('Union SAP Past/Forecast Exp'[Exp])*4.2373,
"QAR",sum('Union SAP Past/Forecast Exp'[Exp])*4.1998,
"OMR",sum('Union SAP Past/Forecast Exp'[Exp])*044363,
"SAR",sum('Union SAP Past/Forecast Exp'[Exp])*4.32672
)
Best Regards
Allan
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Try this
CurCol =
IF( SELECTEDVALUE([Project Currency]) = "AED", 'Union SAP Past/Forecast Exp'[Exp] * 4.2373,
IF( SELECTEDVALUE([Project Currency]) = "QAR", 'Union SAP Past/Forecast Exp'[Exp] * 4.1998,
IF( SELECTEDVALUE([Project Currency]) = "OMR", 'Union SAP Past/Forecast Exp'[Exp] * 0.44363,
IF( SELECTEDVALUE([Project Currency]) = "SAR", 'Union SAP Past/Forecast Exp'[Exp] * 4.32672
)
)
)
)
Regards
Phil
Proud to be a Super User!
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
108 | |
78 | |
66 | |
52 | |
50 |
User | Count |
---|---|
121 | |
120 | |
78 | |
63 | |
62 |