Skip to content

Instantly share code, notes, and snippets.

View catroll's full-sized avatar

胡昂 catroll

View GitHub Profile
@catroll
catroll / sqlalchemy_reflect.py
Created January 31, 2021 03:21 — forked from csabatini/sqlalchemy_reflect.py
Auto-create models from an existing db with SQLAlchemy
from __future__ import print_function
from sqlalchemy import *
from sqlalchemy.orm import create_session
from sqlalchemy.ext.declarative import declarative_base
Base = declarative_base()
engine = \
create_engine("postgresql://...")
metadata = MetaData(bind=engine)
@catroll
catroll / 0_reuse_code.js
Created October 26, 2015 01:27
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console