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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

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
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.