Forum Discussion
Replacing Values based on a Record?
- 2 years ago
Hi Spencer_Bye - Power BI can return the values you are needing using the basic functionality. You will need to add the SQL table with your project management data to your data model and also load the SQL table which contains the employee name and ID. Then in Power BI on the data model tab, draw a relationship between the two tables on the employee ID field in both tables. When you load the two tables to the model PowerBI may create this relationship automatically for you. Then add a table visual on a report page/tab, select the employee names from the employees table and the project information from the projects table. That should result in one table with your projects and employee names that you are looking for.
If you are needing to join these tables in Power Query in order to perform additional transformations on the joined data, then you can merge the two tables. Select the table/query for your projects data. On the ribbon, go to Home and choose Merge Tables > Merge Queries > Merge Queries. Click the employee ID field in the projects table. Then choose the employees table as the 2nd table and select the employee ID field. Choose left outer join to return all rows in the current projects table and matching values from the employees table. When the query is done processing, scroll all the way to the right to see the new column that has been added. Click the diverging arrows button in the column header and expand the column to add the employee names to the table.
Hi Spencer_Bye - Power BI can return the values you are needing using the basic functionality. You will need to add the SQL table with your project management data to your data model and also load the SQL table which contains the employee name and ID. Then in Power BI on the data model tab, draw a relationship between the two tables on the employee ID field in both tables. When you load the two tables to the model PowerBI may create this relationship automatically for you. Then add a table visual on a report page/tab, select the employee names from the employees table and the project information from the projects table. That should result in one table with your projects and employee names that you are looking for.
If you are needing to join these tables in Power Query in order to perform additional transformations on the joined data, then you can merge the two tables. Select the table/query for your projects data. On the ribbon, go to Home and choose Merge Tables > Merge Queries > Merge Queries. Click the employee ID field in the projects table. Then choose the employees table as the 2nd table and select the employee ID field. Choose left outer join to return all rows in the current projects table and matching values from the employees table. When the query is done processing, scroll all the way to the right to see the new column that has been added. Click the diverging arrows button in the column header and expand the column to add the employee names to the table.