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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
thibaug
New Member

Embedded CE (CRM) report changes data type depending on the data

Hi,

We're running into a strange issue while embedding a Power BI report in D365 CE (CRM). We're following the info here. And everything works well except in one case.

We have a string column in CE which has a corresponding column on the Power BI side that is also a string. As long as the content of the column on the CE side is a string, the filter works! But if the column contain a number on the CE side, then it looks like something is converting the value on the fly and Power BI receives a Number. 

So,

Account# - CE (CRM)

Data type

Content

Account# - Power BI

Data type

ContentResult of Filter
String1234aString1234aWorks
String1234String1234Error
String1234Number1234Works

 

Is there something we're missing? Is there a way to specify a data type in the filter XML? 

Thanks in advance!!

Gilles

1 ACCEPTED SOLUTION
thibaug
New Member

Ok, so looks like we've figure it out. Escaping the $a in the filter works. But this appears contradict what Microsoft says in the article. 

Or am I misunderstanding? 

 

  • String fields don't have escaped quotes in the Power BI filter. Below, notice values has [\"$a\"] rather than [$a].

{ "Filter": "[{ \"$schema\":\"basic\", \"target\":{ \"table\":\"My Active Accounts\", \"column\":\"Account Name\" }, \"operator\":\"In\", \"values\":[$a, $b], \"filterType\":1 }]", "Alias": { "$a": "firstname", "$b":"lastname" } }

View solution in original post

1 REPLY 1
thibaug
New Member

Ok, so looks like we've figure it out. Escaping the $a in the filter works. But this appears contradict what Microsoft says in the article. 

Or am I misunderstanding? 

 

  • String fields don't have escaped quotes in the Power BI filter. Below, notice values has [\"$a\"] rather than [$a].

{ "Filter": "[{ \"$schema\":\"basic\", \"target\":{ \"table\":\"My Active Accounts\", \"column\":\"Account Name\" }, \"operator\":\"In\", \"values\":[$a, $b], \"filterType\":1 }]", "Alias": { "$a": "firstname", "$b":"lastname" } }

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors