Forum Discussion
Push Dataset in powerBI
- 6 years ago
Hi khush19
If you can use Power BI Desktop to push data and achieve your requirement,
(there is a blog :Create a Power BI Push DataSet using Power BI Desktop w/ PowerBIPS.Tools)
also you are able to create measures in Power BI Desktop,
you could create the following measures:
date1 = DATE(YEAR(MAX('Table'[datetime])),MONTH(MAX('Table'[datetime])),DAY(MAX('Table'[datetime]))) now = NOW() total_now = CALCULATE(SUM('Table'[amount]),FILTER(ALL('Table'),'Table'[date]=TODAY()&&'Table'[datetime]<=NOW())) total_last week = var lastweek=TODAY()-7 return CALCULATE(SUM('Table'[amount]),FILTER(ALL('Table'),'Table'[date]=lastweek&&'Table'[datetime]<=NOW()-7)) change = [total_now]-[total_last week] change% = [change]/[total_now]Best Regards
MaggieCommunity Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi khush19
If you can use Power BI Desktop to push data and achieve your requirement,
(there is a blog :Create a Power BI Push DataSet using Power BI Desktop w/ PowerBIPS.Tools)
also you are able to create measures in Power BI Desktop,
you could create the following measures:
date1 = DATE(YEAR(MAX('Table'[datetime])),MONTH(MAX('Table'[datetime])),DAY(MAX('Table'[datetime])))
now = NOW()
total_now = CALCULATE(SUM('Table'[amount]),FILTER(ALL('Table'),'Table'[date]=TODAY()&&'Table'[datetime]<=NOW()))
total_last week = var lastweek=TODAY()-7 return CALCULATE(SUM('Table'[amount]),FILTER(ALL('Table'),'Table'[date]=lastweek&&'Table'[datetime]<=NOW()-7))
change = [total_now]-[total_last week]
change% = [change]/[total_now]
Maggie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- khush196 years ago
Resolver I
Thanks Maggie,
But filter doesn't work for me.it return blank
.
I tried putting Today() in different measure but no use.
When i use IF to compare date1 with today() it is correct as required but doesn't work in filter.
- v-juanli-msft6 years ago
Community Support
Hi khush19
Do you use the formula as i provided?
If not, please use my formula instead or show me your formula, i think you may miss something.
Best Regards
MaggieCommunity Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.- khush196 years ago
Resolver I
Yes,I am using your formula:
total_now = CALCULATE(SUM(WeeklyTransactionTable[RealAmount]),FILTER(ALL(WeeklyTransactionTable),WeeklyTransactionTable[date1]=Today()))Infact when i check adding a measure Check=IF(WeeklyTransactionTable[date1]=Today(),"true","fasle"),it works fine.it is just that it doesnt work in filter