def _pragma_foreign_keys(connection, on):
    connection.execute("PRAGMA foreign_keys=%s" % ("ON" if on else "OFF"))


# This dict contains references to downgrade methods that can be applied to an
# assets db. The resulting db's version is the key.
# e.g. The method at key '0' is the downgrade method from v1 to v0
Sets the PRAGMA foreign_keys state of the SQLite database. Disabling
dataset/ETHPy150Open quantopian/zipline/zipline/assets/asset_db_migrations.py/_pragma_foreign_keys