fix help
[rainbowstream.git] / rainbowstream / table_def.py
index f8597f6c47242eca01d3e701cf44b95f7bfd3523..f2435ab30cbe3d3d555dd6bd347959d79137b277 100644 (file)
@@ -4,9 +4,10 @@ from sqlalchemy.ext.declarative import declarative_base
 engine = create_engine('sqlite:///rainbow.db', echo=False)
 Base = declarative_base()
 
-class Map(Base):
 
-    __tablename__ = "map"
+class Tweet(Base):
+
+    __tablename__ = "tweet"
 
     rainbow_id = Column(Integer, primary_key=True)
     tweet_id = Column(Integer)
@@ -14,5 +15,17 @@ class Map(Base):
     def __init__(self, tweet_id):
         self.tweet_id = tweet_id
 
+
+class Message(Base):
+
+    __tablename__ = "message"
+
+    rainbow_id = Column(Integer, primary_key=True)
+    message_id = Column(Integer)
+
+    def __init__(self, message_id):
+        self.message_id = message_id
+
+
 def init_db():
-    Base.metadata.create_all(engine)
\ No newline at end of file
+    Base.metadata.create_all(engine)