convert df to dict one column to another code example Example: pandas to dictionary df.to_dict('records')