Xodarap / tiktok-odds

10 stars 3 forks source link

How do I use it #1

Open mirasaujan opened 3 years ago

mirasaujan commented 3 years ago

umm, how do I use it? I installed all dependencies for python. booted up postresql, though I keep getting an error. I guess the problem is with sql.

cur.execute('INSERT INTO tiktok (time,json) VALUES (%s,%s)', (t_time,new_t)) psycopg2.errors.UndefinedTable: relation "tiktok" does not exist LINE 1: INSERT INTO tiktok (time,json) VALUES ('2020-08-10 20:22:48....

I googled the issue. I guess I have a problem with scheme. What should I do? I am not a python programmer btw)

Xodarap commented 3 years ago

Yeah, you will need to create that table. Or you can just put the data into a CSV if you don't want to do that.

There aren't any migrations in this project, so you'd have to write the SQL yourself. Since this is just a side project for me I'm not sure when I would get around to writing migrations, if ever, but if you or someone else wants to submit a PR I would gladly accept it!