Use INTEGER as data type for follower/following dates

This commit is contained in:
Klaus-Uwe Mitterer 2016-08-01 16:47:10 +02:00
parent 41f5fa288a
commit 2ebe1e10ae

View file

@ -51,8 +51,8 @@ else:
if not db.isInitialized():
db.executeQuery("CREATE TABLE tweets(`tweet_id` INTEGER NOT NULL, `in_reply_to_status_id` TEXT, `in_reply_to_user_id` TEXT, `timestamp` TEXT, `source` TEXT, `text` TEXT, `retweeted_status_id` TEXT, `retweeted_status_user_id` TEXT, `retweeted_status_timestamp` TEXT, `expanded_urls` TEXT, PRIMARY KEY(tweet_id));")
db.executeQuery("CREATE TABLE messages(`id` INTEGER NOT NULL, `text` TEXT, `sender_id` INTEGER, `recipient_id` INTEGER, `created_at` TEXT, PRIMARY KEY(id));")
db.executeQuery("CREATE TABLE followers(`id` INTEGER NOT NULL, `since` TEXT, `until` TEXT);")
db.executeQuery("CREATE TABLE following(`id` INTEGER NOT NULL, `since` TEXT, `until` TEXT);")
db.executeQuery("CREATE TABLE followers(`id` INTEGER NOT NULL, `since` INTEGER, `until` INTEGER);")
db.executeQuery("CREATE TABLE following(`id` INTEGER NOT NULL, `since` INTEGER, `until` INTEGER);")
db.commit()
db.closeConnection()