Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
Dear All,
I got a salesman outlet visit data as MTD which is accumulated daily. How could I create new column or use DAX formula for salesman outlet daily visit? (calculation is outlet_visit_MTD(day n) minus outlet_visit_MTD(day n-1) by salesman) Here is example of the data below. I got the data from the 1st 3 columns and wish to create the 4th column.
Thank you in advanced!
Solved! Go to Solution.
Pay attention to the situation that there are gaps between dates.
Expertise = List.Accumulate( {Days as from Today}, {Skills and Knowledge}, (Current, Everyday) => Current & Day.LearnAndPractise(Everyday) ) |
hi @iteety ,
you may try to add a calculated column like:
Daily2 =
VAR _yyyymmdd = [yyyymmdd]
VAR _mtdpre =
CALCULATE(
MAX(data[MTD]),
ALLEXCEPT(data, data[SalesKey]),
data[yyyymmdd]< _yyyymmdd
)
RETURN [MTD]-_mtdpreor
Daily3 =
VAR _yyyymmdd = [yyyymmdd]
VAR _saleskey = [saleskey]
VAR _mtdpre =
MAXX(
FILTER(
data,
data[saleskey]=_saleskey
&&data[yyyymmdd]<_yyyymmdd
),
data[MTD]
)
RETURN
[MTD] - _mtdpre
they worked like:
Pay attention to the situation that there are gaps between dates.
Expertise = List.Accumulate( {Days as from Today}, {Skills and Knowledge}, (Current, Everyday) => Current & Day.LearnAndPractise(Everyday) ) |
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 9 | |
| 5 | |
| 4 | |
| 4 | |
| 3 |
| User | Count |
|---|---|
| 12 | |
| 10 | |
| 10 | |
| 9 | |
| 8 |