User Profile
tjowen
Regular Visitor
Joined 7 years ago
User Widgets
Contributions
Getting a running average
I have created a calculated table that contains two fields: a date (no time), and a numerical value for each date. It looks something like this: I am trying to get a running average of the previous 30 days for each date. I have tried the following columns: DIVIDE( CALCULATE( SUM(DaySum[Cargo Tonnes]), DATESBETWEEN( 'DaySum'[Date], DATEADD('DaySum'[Date],-30,DAY), 'DaySum'[Date] ) ),30) AND DIVIDE( CALCULATE( SUM(DaySum[Cargo Tonnes]), DATESINPERIOD ( 'DaySum'[Date], DaySum[Date],-30,DAY )),30) AND DIVIDE( CALCULATE( SUM(DaySum[Cargo Tonnes]), DATESBETWEEN( DaySum[Date], FIRSTDATE(DATEADD(DaySum[Date],-30,DAY)), LASTDATE(DaySum[Date]) ) ),30) But the result is always the [Cargo Tonnes] field divided by 30. It never seems to SUM the preceeding 30 days, then divide that sum by 30, thus: Can anyone suggest where I might be going wrong? Thanks! Tom.Solved1KViews0likes1CommentEmbedding reports publicly and privately.
I have a use-case-scenario for Power BI that seems straightforward, but I cannot find any solution online, so I thought I’d reach out to the community… I have two places where I would like to use Power BI. Firstly, I would like anybody to be able to visit the public part of our website and have a look at a report that I have created. The report that I have created aggregates our data but excludes the last 6 months of data. I know that I can share a report online easily by embedding the report in a public part of our site using “Publish to web” – but can anyone let me know if it is only the aggregated data as presented in the report that is available to the public, or would they also be able to download the underlying data too? Secondly, for those who are our customers, we have a secure part of our website that they can access. I would like to make a report available within that secure part of the site. This report will not have the limitation where the last 6 months of data is hidden, and users may download the underlying data. However, as far as I understand if I use “Publish to web” to share the report online and embed it in this private part of the site, anyone can potentially still find that report and see it. Of course, that’s a problem. So, I was looking at using the simple embed option (https://docs.microsoft.com/en-us/power-bi/service-embed-secure) where I could embed the report securely. BUT this means that anyone who wants to use the report needs to sign-in to Power BI and, of course, I cannot tell whether our customers are Power BI consumers already and, even if they were, it’s also a poor experience to force them to sign-into Power BI when they have already logged into our site. So – can anyone let me know how to embed a report within a page of my choosing, but without making the report public and without forcing users to sign-in to Power BI to view the report? Many thanks! Tom618Views0likes2Comments
Data Privacy
Microsoft Fabric Community and Privacy
To learn more about how we manage your data, please review the Microsoft Fabric Community Data Privacy guide.