I'm very much stuck in here. I want to send pandas dataframe to MySQL servers. df.to_sql('table_name', if_exists='append', con=connection_string, index=False) it kept showing me the error: (pymysql.err.IntegrityError) (1062, "Duplicate entry '(value)' for key '(table).PRIMARY'") all the value in Primary key column is unique, and there are no duplicated. Continue reading...