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
nirajdubey
Advocate I
Advocate I

Delay in applying filter in embedded

I am using power BI embedded in my web application. I am using javs script library 2.0 provided on Git. my filter is working as desired. The problem is report is loaded with all the data and filter is getting applied there after, and hence user will be able to have a glimpse of all records for which he soes not have access. How can I reduce this delay. We have also implemented RLS in data source which is a SSAS cube, how can we pass user information to PBI?

Follwoing is the java script code to call PBI report

 

var defaultFilter = {

            target: {

                table: "Table1",

                column: "Column1"

            },

            operator: "In",

            values: ["H "]

        };

 

var embedConfiguration = {

                type: 'report',

                accessToken:’Token’,

                id: ReportId',

                embedUrl: 'https://embedded.powerbi.com/appTokenReportEmbed',

                settings: {

                    filterPaneEnabled: true

                }

           };

 

            var $reportContainer = $('#reportContainer');

           

            var report = powerbi.embed($reportContainer.get(0), embedConfiguration);

            report.on('loaded', event => {

                report.getFilters()

                  .then(filters => {

                      filters.push(defaultFilter);

            return report.setFilters(filters);

        });

        });

 

4 REPLIES 4
dpanaite
Frequent Visitor

Any solution here?

Step by step to see this delay, since this Angular demo default filter doesn't work and javascript demo have no interface way to do that:

 

  1. Access this demo: https://microsoft.github.io/PowerBI-JavaScript/demo/v2-demo/index.html
  2. Click on "Embed Report"
  3. Open console from your browser
  4. Execute this function:  _Embed_EmbedWithDefaultFilter()
  5. There we are the 0.5 seconds that affects directly the client data confidence

Come on.. we are already defining the default filter BEFORE to create the object. We know this daley can be fixed.

 

We are trying to do a workaround to use the same report for more than one client. Otherwise it will be impossible to managing that. Pleaseee, provide parameters for powerbi service! Smiley Happy

Hey @nirajdubey  this link really save my life 🙂   I'm not sure if it is applied for SASS

https://powerbi.microsoft.com/en-us/documentation/powerbi-developer-embedded-rls/

ONE line difference and a small adjustment on power bi desktop.

 

Also, they updated the sample https://github.com/Microsoft/PowerBI-Developer-Samples/tree/master/App%20Owns%20Data

 

Enjoy

KumarDarmesh
Helper IV
Helper IV

I guess you can't apply RLS in SSAS, try the RLS in power bi.

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