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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Siduna
Frequent Visitor

Newbie trying to figure out how to structure data for a Gantt chart

I have some tables I need to process in order to create a Gannt chart. I wish to sort the tasks/roles per person. The challenge is that I have one table (A) that includes the dates for the Gantt chart and the id of the project managers. The same persons can also be assigned projects without leading them. This is stored in another table (B) with reference to the file that contains project data (A).

When I build this in Microsoft Acess I simply created a query that created a table containing ProjectID, PersonId and Role ("Lead" or "Assisting"). I then linked this table to others to get the additional data I needed. Can this be done in Power BI or can I get the result in any other way?

The "resource" column in the Gantt chart would like something below (and the the Gantt bars would follow to the right):

 

Name      Role

Mike P     Lead

                Assisting

Peter N    Lead

                Lead

                Assisting

1 ACCEPTED SOLUTION
AmiraBedh
Super User
Super User

 

In PQ, use  "Append Queries"  to combine your tables. You should have a table where each row contains a ProjectID, PersonID, Role (Lead or Assisting), Start Date, and End Date.

 

Then create a calculated column :

 

Resource = TableA[PersonID] & " - " & TableA[Role]

 

Then create your Gantt chart.

 


Proud to be a Power BI Super User !

Microsoft Community : https://docs.microsoft.com/en-us/users/AmiraBedhiafi
Linkedin : https://www.linkedin.com/in/amira-bedhiafi/
StackOverflow : https://stackoverflow.com/users/9517769/amira-bedhiafi
C-Sharp Corner : https://www.c-sharpcorner.com/members/amira-bedhiafi
Power BI Community :https://community.powerbi.com/t5/user/viewprofilepage/user-id/332696

View solution in original post

1 REPLY 1
AmiraBedh
Super User
Super User

 

In PQ, use  "Append Queries"  to combine your tables. You should have a table where each row contains a ProjectID, PersonID, Role (Lead or Assisting), Start Date, and End Date.

 

Then create a calculated column :

 

Resource = TableA[PersonID] & " - " & TableA[Role]

 

Then create your Gantt chart.

 


Proud to be a Power BI Super User !

Microsoft Community : https://docs.microsoft.com/en-us/users/AmiraBedhiafi
Linkedin : https://www.linkedin.com/in/amira-bedhiafi/
StackOverflow : https://stackoverflow.com/users/9517769/amira-bedhiafi
C-Sharp Corner : https://www.c-sharpcorner.com/members/amira-bedhiafi
Power BI Community :https://community.powerbi.com/t5/user/viewprofilepage/user-id/332696

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Feb2025 Sticker Challenge

Join our Community Sticker Challenge 2025

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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