Hi @LucasSalomons-0933
No worries at all. As you seem to be new on the forum: when a proposal solves your problem, it's a good habit to accept it as answer in order to help those who search before posting
Below is another option that is easier to understand for someone who begins with PQ where, inside Table.Group I decomposed the steps, hopefully with names that talk:
let
// Table for demo.
Source = Table.FromColumns(
{
List.Dates(#date(2020,7,2), 15, #duration(2,0,0,0)),
List.Repeat({"A"}, 4) & List.Repeat({"B"}, 6)
& List.Repeat({"C"}, 5)
},
type table [Date = date, Product = text]
),
GroupedProduct = Table.Group(Source, {"Product"},
{"TBL", each
let
DatesAsList = Table.Column(_, "Date"),
MaxInList = List.Max(DatesAsList),
AddedColumn = Table.AddColumn(_, "Date Max", each
MaxInList, type date
)
in
AddedColumn,
type table
}
),
CombinedNestedTables = Table.Combine(GroupedProduct[TBL])
in
CombinedNestedTables
Any question let me know - not to explain every steps though :) as you're right a bit of home work is required
Just in case, PQ documentation is available here
Cheers