简体   繁体   中英

SQL Join using 4 different tables

I am a SQL beginner and trying to figure out what the following AND statement means in this SQL join

 LEFT JOIN [Galatasaray].[dbo].[Groups] ON [Ajax].[Flowers] = 
 [Groups].[Tree] 
 AND [Results].[BGF] = [Outcome].[label]

I am using the following pandas statement to refactor this in python, but I am not sure how to continue and include the AND statement.

Merge3 = pd.merge(Ajax, Galatasaray, on = 
'Flowers',how = 'left')

Please use like this,

Result_df = pd.merge(df_1, df_2,  how='left', left_on=['c1','c2'], right_on = ['c1','c2'])

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM