import sqlalchemy as sa from .database import database engine = sa.create_engine(database) metadata = sa.MetaData() metadata.create_all(engine) for tbl in reversed(metadata.sorted_tables): engine.execute(tbl.delete())
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter