0
Hello. I am working on a personal project and need a help. I have 2 dataframes:
solicitacoes = pd.DataFrame({'ID':[1,2,4,5],
'Equipe':['A','B','C','D','E'],
'Emissor_da_ordem':['Joao Pedro','Maria Teresa', 'Ricardo Duarte', 'Iago Matos', 'Tiago Nogueira'],
'Emissor_da_ordem_login':['AD_JP','CR_MT','AD_RD','0345','321'],
})
incidentes = pd.DataFrame({'ID':[7,8,9,10,11],
'Equipe':['A','B','C','D','E'],
'Emissor_da_ordem':'',
'Emissor_da_ordem_login':['AD_JP','CR_LD','AD_RD','0345','9999']
})
I would like to fill in each row of the incident column['Emissor_da_ordem'] with the name of its sender from its login ( incidents['Emissor_da_ordem_login'] ). Ex.: Fill in the first row of the incident column['Emissor_da_ordem'] = 'Joao Pedro'. For this I have the dataframe requests.
How can I do this with the pandas?
Note: The two tables are generated by the same system and a login corresponds to only one person. Note: Some values in incidents['Emissor_da_ordem_login'] may not be found in requests['Emissor_da_ordem_login'].
From now on, thank you very much
Welcome to the SO-PT, Leonardo! Your question is missing some information for the full understanding of the problem. Please read how to create a minimal and verifiable example. Take the opportunity and add in the question how should be the output of the correct answer.
– Terry