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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
artlemaks
Helper II
Helper II

Embed reports without the need to sign in and problem with filters in URL

Hi everyone! 

 

I am coming across a couple of issues with making the reports visible to our customers. 

So the first issue I am facing, is when I embed the report on our website, it is asking for a sign-in. I understand that publishing it to web would resolve that issue, but that's not an option since we are dealing with sensitive data. Is there a way to disable that, or at least automatically sign user into an account in the backgroud? 

 

The 2nd issue that I am facing is to do with passing filters in the URL. As suggested in Microsoft Docs, I am using

URL?filter=Table/Field eq 'value'

So my URL would look like URL?filter=store_master/customer_id eq 11

However when I do that, I do see a field added in the filters section, but it has a yellow exclamation mark and says that "This filter came from a query string parameter that was added to a report URL." and the value assigned to it is (All) instead of the 11 specified in the URL. 

Am I missing something very obvious? 

 

Thank you for any assistance.

1 ACCEPTED SOLUTION

@artlemaks 

 

Refer to this https://powerbi.microsoft.com/en-us/blog/easily-embed-secure-power-bi-reports-in-your-internal-porta...

Capture.JPG

 

As per the below blog, field type should be a string. So can you create a calculated column to convert the whole number to text and see if it is working?

https://powerbi.microsoft.com/en-us/blog/filter-a-report-with-a-url-query-string-parameter/



Did I answer your question? Mark my post as a solution!
Appreciate with a kudos
🙂


Regards,
Nandu Krishna

View solution in original post

9 REPLIES 9
nandukrishnavs
Super User
Super User

@artlemaks 

 

Since you are using secure embed, it will ask sign-in. 

You can explore the Power BI embedded. https://docs.microsoft.com/en-us/power-bi/developer/embedded/embedding

 

Regarding your 2nd question 

  • Table and Field names are case-sensitive, value isn't.
  • Verify the type of customer_id, if it is text use single quotes



Did I answer your question? Mark my post as a solution!
Appreciate with a kudos
🙂


Regards,
Nandu Krishna

Thank you for your reply @nandukrishnavs . Is there no way to bypass the sign-in screen without Power BI Embedded? Are there no APIs that I can use to perform a Sign-In in the background? 

 

With my filters issue, I understand that table and field names are case sensitive. I am assuming that Power BI is recognizing the field that I am looking for, as it does appear in the Filters pane on the right hand side. The problem seems to be that the value is not getting assigned to it. The type of customer_id is whole number, so the way I have in my URL, without single quotes, should work fine. 

@artlemaks 

 

Refer to this https://powerbi.microsoft.com/en-us/blog/easily-embed-secure-power-bi-reports-in-your-internal-porta...

Capture.JPG

 

As per the below blog, field type should be a string. So can you create a calculated column to convert the whole number to text and see if it is working?

https://powerbi.microsoft.com/en-us/blog/filter-a-report-with-a-url-query-string-parameter/



Did I answer your question? Mark my post as a solution!
Appreciate with a kudos
🙂


Regards,
Nandu Krishna

@nandukrishnavs still no luck with the filters. 

 

Now, in the fields section, the table name is godigitally_easycoun_st store_master. I pressume that I use the whole name in the string query, which is godigitally_easycoun_st store_master, rather than just store_master? I've tried both ways though and every time I am ending with a field with a yellow exclamation mark set to (All). 

@artlemaks  Try to remove the special characters from the tables and columns and try again with sample dataset.


Regards,
Nandu Krishna

@nandukrishnavs special characters being white spaces? I can't think of any other special characters that I might have in the dataset. 

@artlemaks  For example 

godigitally_easycoun_st store_master ==> godigitallyeasycounststoremaster

 

Special characters and spaces in table and column names require some additional formatting.

https://docs.microsoft.com/en-us/power-bi/collaborate-share/service-url-filters#special-characters-i...



Did I answer your question? Mark my post as a solution!
Appreciate with a kudos
🙂


Regards,
Nandu Krishna

@nandukrishnavs okay, so that worked! I can use the query string in the URL and adjust the filters that way when working on the Power BI dashboard online.

 

Now, when it comes to implementing it into the iFrame. Is it just a matter of doing the following

&filter=storemaster%2Fcustomer_id_str%20eq%20%27<? echo $customer_id; ?>%27 ? I have copied the string from my browser and pasted into the embeded URL in the iFrame. So all I have done was replaced this filter=storemaster%2Fcustomer_id_str%20eq%20%2715%27 with the code above, because $customer_id in the example that I am testing is 15. However, that shows me no results. Am I being too optimistic with trying to do it that way? 

@artlemaks  Copy your iframe URL and test it before embedding the report. Go through this  https://docs.microsoft.com/en-us/power-bi/collaborate-share/service-url-filters and make sure you are not doing any manual errors.

 


Regards,
Nandu Krishna

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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

Top Solution Authors
Top Kudoed Authors