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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
negro57
New Member

Weekly kilometers

I have a table where I register the kilometers that have the vehicles, I want to know the kilometers that traveled, subtracting the settlers the previous week and the settled ones this week.

What I need is to know the weekly kilometers traveled and to be able to compare with the routes in the previous weeks
Sorry for my english, I hope you understood me, thank you

1 ACCEPTED SOLUTION
Vvelarde
Community Champion
Community Champion

 

@negro57

 

create a calculated colum:

 

KRecorridosP =
CALCULATE (
    SUM ( Table1[Kilometros] ),
    FILTER ( ALLEXCEPT ( Table1,Table1[Dominio] ), Table1[Fecha] = EARLIER ( Table1[Fecha] ) - 7 )
)

 

 

 




Lima - Peru

View solution in original post

6 REPLIES 6
negro57
New Member

 

Presentación1.jpg

 

I need in each row to calculate the number of km made by the vehicle from the previous load

 

Captura de pantalla 2017-01-16 15.08.40.png

I do not understand why it does not complete the data in the column (column)

Vvelarde
Community Champion
Community Champion

 

@negro57

 

create a calculated colum:

 

KRecorridosP =
CALCULATE (
    SUM ( Table1[Kilometros] ),
    FILTER ( ALLEXCEPT ( Table1,Table1[Dominio] ), Table1[Fecha] = EARLIER ( Table1[Fecha] ) - 7 )
)

 

 

 




Lima - Peru

So now I only have to subtract kilometers and this column excellent thousand thanks

tringuyenminh92
Memorable Member
Memorable Member

Hi @negro57,

 

Could you please share your data sample or data structure and your expectation as picture? so I could quickly figure out and propose solution.Smiley Very Happy 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.