Max query with second condition  [Solved]

Msoede
Posts: 2
Joined: Tue Sep 11, 2018 6:02 am

Max query with second condition

Postby Msoede » Tue Sep 11, 2018 6:16 am

Hi all,

Simple question. I have a data set containing transactions with a limited set of fields of which one is a time stamp and the other one the value of the transation.

Question is if it possible in power query to take the most recent timestap of which the value is not 0? Some of the most recent timestamps have a 0 value and in that case I need to pick the most recent timestamp with a value (the one before the most recent timestamp). All other (6) fields in the table are equal.

Grateful for a swift response

Michiel

MattAllington
Posts: 985
Joined: Sun May 04, 2014 4:01 pm
Location: Sydney, Australia

Re: Max query with second condition  [Solved]

Postby MattAllington » Tue Sep 11, 2018 6:25 am

Just put a filter to remove the zeros, then group by and take the first record.
Matt Allington is Self Service BI Consultant, Trainer and Author of the Book "Supercharge Power BI".
Power BI Training

Msoede
Posts: 2
Joined: Tue Sep 11, 2018 6:02 am

Re: Max query with second condition

Postby Msoede » Tue Sep 11, 2018 7:36 am

Thanks. How could I overlook the filter. :-s


Return to “Power Query”

Who is online

Users browsing this forum: No registered users and 1 guest