Skip to content

Instantly share code, notes, and snippets.

@octaflop
Last active November 8, 2018 03:05
Show Gist options
  • Save octaflop/803932bf781bb78cfde6b15d1104f546 to your computer and use it in GitHub Desktop.
Save octaflop/803932bf781bb78cfde6b15d1104f546 to your computer and use it in GitHub Desktop.
# Via https://docs.sqlalchemy.org/en/latest/orm/tutorial.html
class User(Base):
__tablename__ = 'users'
id = Column(Integer, primary_key=True)
name = Column(String)
fullname = Column(String)
password = Column(String)
def __repr__(self):
return "<User(name='%s', fullname='%s', password='%s')>" % (
self.name, self.fullname, self.password)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment