cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
mrainey Member
Member

Using earliest and latest dates

I have this table:

1.PNG

I currently cannot establish a relationship to this table because of duplication. How can I transform this into one record using the earliest start date (1/1/2017) and the latest enddate (12/31/2100)?

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Using earliest and latest dates

Hi @mrainey,

 

Please download the solutions from the attachment. You can achieve it either by Power Query or by DAX.

1. Using Power Query "Group by" function.

2. DAX.

Table =
SUMMARIZE (
    'Table2',
    Table2[Co],
    "startDate", MIN ( 'Table2'[startDate] ),
    "endDate", MAX ( 'Table2'[endDate] )
)

using-earliest-and-latest

 

Best Regards,
Dale

Community Support Team _ Dale
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
1 REPLY 1
Community Support Team
Community Support Team

Re: Using earliest and latest dates

Hi @mrainey,

 

Please download the solutions from the attachment. You can achieve it either by Power Query or by DAX.

1. Using Power Query "Group by" function.

2. DAX.

Table =
SUMMARIZE (
    'Table2',
    Table2[Co],
    "startDate", MIN ( 'Table2'[startDate] ),
    "endDate", MAX ( 'Table2'[endDate] )
)

using-earliest-and-latest

 

Best Regards,
Dale

Community Support Team _ Dale
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.