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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
ToniMuñoz
Frequent Visitor

Help! send measure using REST API

Hello!

I have created Dataset (using rest api) with simple measure and code is ok.

Like this :

      'measures': [
        {
          'name': 'Totales',
          'expression': 'sum(Data[Pendientes])',
          'formatString': '0'
        }
      ]
But when i use filters 
      'measures': [
        {
          'name': 'Totales',
          'expression': 'calculate(MAX(Data[Pendientes]),FILTER(Data,Data[TIPO]="T")))',
          'formatString': '0'
        }
      ]
I have a problem with quotation marks, i try with simple, double, but now i cant create dataset... if i remove the expression for simple its ok. 
Can u help me?
 
Sorry @ my english!
1 REPLY 1
ToniMuñoz
Frequent Visitor

Solved with this Measure

 

      'measures': [
        {
          'name': 'Totales2',
          'expression': 'calculate(sum(Data[Pendientes]),filter(Data,Data[ID]=MAX(Data[ID]) && Data[TIPO]=""T""))',
          'formatString': '0'
        }
      ]
 

 

My problem was not in quote marks i thik that measure was not correct. 

 

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.