Pandas dtype to SQLAlchemy mapping

Viewed 796

Is there such a thing as a "built-in" mapping between Pandas supported dtypes and SQLAlchemy datatypes?

I am trying to find more elegant way to produce a SQLAlchemy schema from a dataframe than iterating through all cases... Or somehow intercept the schema to_sql would produce, without directly writing.

Browsing Pandas to_sql sources gives me the impression that this is done case by case (sql._sqlalchemy_type definition). So what I am looking for might not exist...

0 Answers
Related