I have two tables, on is called df_information. This table just have information about each user. Here is how it looks:
id_user | job_function | job_area | title |
---|---|---|---|
1123 | Compensation / Benefit Policy | Human Resources | personnel |
1124 | HR Systems Administration | Human Resources | personnel |
1124 | Cyber Security / Information Security | IT / Computers / Electronic | personnel |
1125 | Equipment | Manufacturing / Production / Operations | manager |
1602 | Product Development | IT / Computers / Electronics | director |
And I have second table that is called df_all_possible_job_function_job_area. This table has job_function and job_area combinations that are not included in df_information for each title.
job_function | job_area | title |
---|---|---|
ASIC / Layout Design | TwoIT / Computers / Electronics | director |
Accounting | Finance / Accounting | personnel |
Accounts Payable | Finance / Accounting | personnel |
Account Management | Customer Support / Client Services | personnel |
I want to merge df_information with df_all_possible_job_function_job_area, but the thing is each job_function, job_area combination for each title in df_information should be merged for every id_user, for example if merging two small dataframe above, something like this should be gotten in result:
id_user | job_function | job_area | title |
---|---|---|---|
1123 | Compensation / Benefit Policy | Human Resources | personnel |
1123 | Accounting | Finance / Accounting | personnel |
1123 | Accounting | Finance / Accounting | personnel |
1123 | Accounts Payable | Finance / Accounting | personnel |
1123 | Account Management | Customer Support / Client Services | personnel |
1124 | HR Systems Administration | Human Resources | personnel |
1124 | Cyber Security / Information Security | IT / Computers / Electronic | personnel |
1124 | Accounting | Finance / Accounting | personnel |
1124 | Accounting | Finance / Accounting | personnel |
1124 | Accounts Payable | Finance / Accounting | personnel |
1124 | Account Management | Customer Support / Client Services | personnel |
1125 | Equipment | Manufacturing / Production / Operations | manager |
1602 | Product Development | IT / Computers / Electronics | director |
1602 | ASIC / Layout Design | TwoIT / Computers / Electronics | director |