Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply

Need help with parameter

I have create a parameter named 'AssetID'

parvathisuku_90_0-1600328976855.png

I need to use the same parameter in my measure 

Per Asset = CALCULATE(
    AVERAGE('cbdb alarm_occurences'[qty_alarms_7day]),
    'cbdb alarm_occurences'[grid_element_key]
        IN { "75e76b7c-19f3-4119-a043-859331e74c12" }
Instead of "75e76b7c-19f3-4119-a043-859331e74c12" I want use parameter AssetID
Can some please help
5 ACCEPTED SOLUTIONS
nandukrishnavs
Super User
Super User

@parvathisuku_90 

 

You cannot directly use the parameter inside the DAX measure. But you can create a reference of the parameter. Then it will act as a table. After that, you can use it in DAX measure.

 

Attaching the PBIX file for your reference.

 


Regards,
Nandu Krishna

View solution in original post

How can I convert parameter to table. Can you please provide an example.

View solution in original post

@parvathisuku_90 

 

  1. Open Edit Query window
  2. Right-click on Parameter
    1. nandukrishnavs_0-1600349173942.png

       

  3. Click Reference
  4. Then click on convert To Table
    1. nandukrishnavs_1-1600349258185.png

       

 


Regards,
Nandu Krishna

View solution in original post

@parvathisuku_90 

 

after = symbol, you could use selectedvalue() for getting the value.

selectedvalue() 

 


Regards,
Nandu Krishna

View solution in original post

Thank you!!!!! Working fine...

 

 

View solution in original post

7 REPLIES 7
nandukrishnavs
Super User
Super User

@parvathisuku_90 

 

You cannot directly use the parameter inside the DAX measure. But you can create a reference of the parameter. Then it will act as a table. After that, you can use it in DAX measure.

 

Attaching the PBIX file for your reference.

 


Regards,
Nandu Krishna

How can I convert parameter to table. Can you please provide an example.

@parvathisuku_90 

 

  1. Open Edit Query window
  2. Right-click on Parameter
    1. nandukrishnavs_0-1600349173942.png

       

  3. Click Reference
  4. Then click on convert To Table
    1. nandukrishnavs_1-1600349258185.png

       

 


Regards,
Nandu Krishna

As mentioned, I have added the table.But not able to access the same in my measure

parvathisuku_90_0-1600762553272.png

 

@parvathisuku_90 

 

after = symbol, you could use selectedvalue() for getting the value.

selectedvalue() 

 


Regards,
Nandu Krishna

Thank you!!!!! Working fine...

 

 

Hi @parvathisuku_90 ,

If the problem has been resolved, could you please mark the helpful post as Answered? It will help other members in the community find the solution easily if they face the similar problem with you. Thank you.

Best Regards

Rena

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.