Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more
For the option if_exists='replace' in write_frame the table is dropped but not re-created.
Simple error in the logic:
#create or drop-recreate if necessary
create = None
if exists and if_exists == 'replace':
create = "DROP TABLE %s" % name
elif not exists:
create = get_schema(frame, name, flavor)
if create is not None:
cur = con.cursor()
cur.execute(create)
cur.close()
For the option if_exists='replace' in write_frame the table is dropped but not re-created. Simple error in the logic: