diff --git a/build_database.py b/build_database.py index 12aa89f..5917a7d 100644 --- a/build_database.py +++ b/build_database.py @@ -184,7 +184,7 @@ async def main_with_ctx(ctx, wanted_date): for row in tags_reader: tag = Tag(int(row[0]), row[1], int(row[2]), int(row[3])) await ctx.db.execute( - "insert into tags (id, name, category, post_count) values (?, ?, ?, ?)", + "insert into tags (id, name, category, post_count) values (?, ?, ?, ?) on conflict do nothing", (tag.id, tag.name, tag.category, tag.post_count), ) processed_count += 1 @@ -262,7 +262,7 @@ async def main_with_ctx(ctx, wanted_date): up_score, down_score, is_rating_locked - ) values (?,?,?,?,?,?,?,?,?,?,?,?,?,?) + ) values (?,?,?,?,?,?,?,?,?,?,?,?,?,?) on conflict do nothing """, ( post.id,