Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Hi There,
I need to have your help to solve an issue that i have. Indeed, i have the following main table with employee and list of start date and end date (phases per month) I would like to have this phase per year with the start date and end date as desscribed below
how can i achieved this ?
Thanks a lot for your help
Frédéric
Solved! Go to Solution.
Hi @frederic_FAURE , check this:
Output
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("bdFLCsAgDATQqxTXRUz81Xt0Jy57gvb+tFIwDMxy5GWEpHd3XvfjdqfVb+I3DZq+FMXS2BeaT8tos4QmQk+kJpkJltBk6MnUFOgp1FToqdQcYA5qGvzVqJGASwxcCVQJ37UodvFt/7MZrpbp1aapFsZ4AQ==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [EmpName = _t, start = _t, end = _t]),
ChangedType = Table.TransformColumnTypes(Source,{{"EmpName", type text}, {"start", type date}, {"end", type date}}),
RenamedColumns = Table.RenameColumns(ChangedType,{{"start", "startDate"}, {"end", "endDate"}}),
GroupedRows = Table.Group(RenamedColumns, {"EmpName", "startDate"}, {{"start", each List.Min([startDate]), type date}, {"end", each List.Max([endDate]), type date}}, 0,
(x,y)=> Value.Compare(Date.StartOfYear(y[startDate]), Date.StartOfYear(x[startDate])) ),
RemovedColumns = Table.RemoveColumns(GroupedRows,{"startDate"})
in
RemovedColumns
This is the proces for solving your problem, consider the below table (column Start and end are in type Date)
select start column and from add column tab, Date section, pick Year (as below)
then select the column EmpName and Year (added by the previous step) and from home tab pick group by command and make the below setting
it solve the problem and results in
Thanks a lot for the quick anwsers !
Hi @frederic_FAURE ,
Thanks for all the replies!
And @frederic_FAURE , if Omid_Motamedise's and frederic_FAURE's replies can help you solve your problem, please remember to accept their replies as solutions to help the other members find it more quickly. Thank you!
Best Regards,
Dino Tao
This is the proces for solving your problem, consider the below table (column Start and end are in type Date)
select start column and from add column tab, Date section, pick Year (as below)
then select the column EmpName and Year (added by the previous step) and from home tab pick group by command and make the below setting
it solve the problem and results in
Hi @frederic_FAURE , check this:
Output
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("bdFLCsAgDATQqxTXRUz81Xt0Jy57gvb+tFIwDMxy5GWEpHd3XvfjdqfVb+I3DZq+FMXS2BeaT8tos4QmQk+kJpkJltBk6MnUFOgp1FToqdQcYA5qGvzVqJGASwxcCVQJ37UodvFt/7MZrpbp1aapFsZ4AQ==", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [EmpName = _t, start = _t, end = _t]),
ChangedType = Table.TransformColumnTypes(Source,{{"EmpName", type text}, {"start", type date}, {"end", type date}}),
RenamedColumns = Table.RenameColumns(ChangedType,{{"start", "startDate"}, {"end", "endDate"}}),
GroupedRows = Table.Group(RenamedColumns, {"EmpName", "startDate"}, {{"start", each List.Min([startDate]), type date}, {"end", each List.Max([endDate]), type date}}, 0,
(x,y)=> Value.Compare(Date.StartOfYear(y[startDate]), Date.StartOfYear(x[startDate])) ),
RemovedColumns = Table.RemoveColumns(GroupedRows,{"startDate"})
in
RemovedColumns
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 7 | |
| 6 | |
| 4 | |
| 3 | |
| 3 |
| User | Count |
|---|---|
| 12 | |
| 12 | |
| 10 | |
| 6 | |
| 5 |