From 363aaf46fde7e83f3b472ef5668b0eb1c02e4ac5 Mon Sep 17 00:00:00 2001 From: "Antonio J. Delgado" Date: Sun, 29 Jan 2023 15:18:41 +0200 Subject: [PATCH] fix insert --- find_duplicate_files/find_duplicate_files.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/find_duplicate_files/find_duplicate_files.py b/find_duplicate_files/find_duplicate_files.py index 63b256d..b0b1d1e 100644 --- a/find_duplicate_files/find_duplicate_files.py +++ b/find_duplicate_files/find_duplicate_files.py @@ -76,7 +76,7 @@ class find_duplicate_files: def _cache_file(self, file, hash): file_sql = file.replace("'", "''") - query = f"INSERT INTO files (hash, file) VALUES ('{file_sql}', '{hash}')" + query = f"INSERT INTO files (file, hash) VALUES ('{file_sql}', '{hash}')" if isinstance(query, bytes): query = query.decode('utf-8') try: