left = pd.DataFrame({'key': ['a', 'b', 'c'],
'value': [1, 2, 3]})
left
right = pd.DataFrame({'key': ['a', 'b', 'd'],
'value': [1, 2, 4]})
right
left.merge(right, on=['key'], how='left')
left.join(right.set_index('key'), on=['key'],
lsuffix='_x', rsuffix='_y')