Created
January 27, 2016 13:10
-
-
Save nguyenkims/403e5986e4fa8121a63a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Animal(db.Model): | |
__abstract__ = True | |
id = db.Column(db.Integer, primary_key=True) | |
name = db.Column(db.String(100)) | |
class Cat(Animal): | |
__tablename__ = "cat" | |
meo = db.Column(db.String(10)) | |
class Dog(Animal): | |
__tablename__ = "dog" | |
cho = db.Column(db.String(10)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment