The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello
I have a table in my model that contains parameters (i.e : (key, value)):
The table has 2 columns :
- ParamName : Name of the parameter (string)
- ParamValue : Value of the parameter (may be string, integer, date)
How can I create measure that returns the ParamValue based on a given ParamName ?
I tried that, but it does not work :
Measure =FIRSTNONBLANK(PARAM[ParamValue ];PARAM[ParamName ]="TheNameOfTheParameter")
Thanks
Solved! Go to Solution.
Hi @jct999 -
You can use LOOKUPVALUE for this:
Measure =
var __PN = SELECTEDVALUE(PARAM[ParamName])
RETURN
LOOKUPVALUE ( PARAM[ParamValue], PARAM[ParanName], __PN )
Hope this helps
David
Hi @jct999 -
You can use LOOKUPVALUE for this:
Measure =
var __PN = SELECTEDVALUE(PARAM[ParamName])
RETURN
LOOKUPVALUE ( PARAM[ParamValue], PARAM[ParanName], __PN )
Hope this helps
David
User | Count |
---|---|
27 | |
12 | |
8 | |
7 | |
5 |
User | Count |
---|---|
35 | |
14 | |
12 | |
6 | |
6 |