Hi there,
I have transform the Qliksense App to Power BI App -
if anyone can assist - I have a script like below
//Latest Snapshot Calculation
MaxDate:
Load Max(_Date) as _MaxDate
Resident PH;
LET vTMP_Max_Date = Num(Peek('_MaxDate', 0, 'MaxDate'));
MaxDateNSLHD:
Load Max(_Date) as _MaxDate_NSLHD
Resident PH
where PH.count_ph_resident_nslhd=1;// "Owning Jurisdiction"='Hornsby';
LET vTMP_Max_Date_NSLHD = Num(Peek('_MaxDate_NSLHD', 0, 'MaxDateNSLHD'));
drop table MaxDate;
Drop table MaxDateNSLHD;
Join(PH)
load distinct _Date,
_Date as _Doubling_Rate_Linkage,
Interval($(vTMP_Max_Date) - _Date,'d') As PH.Last_n_days,
Interval($(vTMP_Max_Date_NSLHD) - _Date,'d') As PH.Last_n_days_NSLHD,
if(Interval($(vTMP_Max_Date) - _Date,'d') =0,1,0) as PH.count_today,
if(Interval($(vTMP_Max_Date) - _Date,'d') =7,1,0) as PH.count_7_days_ago,
if(Interval($(vTMP_Max_Date) - _Date,'d') < 7,1,0) as PH.count_last_7_days,
if(Interval($(vTMP_Max_Date) - _Date,'d') < 3,1,0) as PH.count_last_3_days
resident PH
;
How can I implement this in Power Bi ?
Thanks
You need to show us your sample data and what you are trying to do.
How to get good help fast. Help us help you.
How To Ask A Technical Question If you Really Want An Answer
How to Get Your Question Answered Quickly - Give us a good and concise explanation
How to provide sample data in the Power BI Forum - Provide data in a table format per the link, or share an Excel/CSV file via OneDrive, Dropbox, etc.. Provide expected output using a screenshot of Excel or other image. Do not provide a screenshot of the source data. I cannot paste an image into Power BI tables.
DAX is for Analysis. Power Query is for Data Modeling
Proud to be a Super User!
MCSA: BI ReportingCome together to explore latest innovations in code and application development—and gain insights from experts from around the world.
Welcome to the Power BI Community Show! Jeroen ter Heerdt talks about the importance of Data Modeling.
Mark your calendars and join us on Thursday, May 26 at 11a PDT for a great session with Ted Pattison!
User | Count |
---|---|
141 | |
25 | |
22 | |
10 | |
9 |
User | Count |
---|---|
150 | |
40 | |
31 | |
18 | |
17 |