diff --git a/prompt_generator.py b/prompt_generator.py index 9f0f9d1..4fa4334 100644 --- a/prompt_generator.py +++ b/prompt_generator.py @@ -70,10 +70,18 @@ class SqliteHandle: self.__cursor.execute(f"DELETE from `{self.__table}` where id BETWEEN 1 AND 21") self.__connect.commit() -sqlite_handle = SqliteHandle -if __name__ == '__main__': + def delete_tabls(self, tab): + self.__cursor.execute(f"DROP TABLE `{tab}`;") + self.__connect.commit() + +def cp_db_data(): sql_ll = sqlite_handle(database='ai_prompt_cp.db') tabs = sql_ll.get_tables() for i in tabs: old_data = sqlite_handle(table=i, database='ai_prompt_cp.db').get_prompt_value() sqlite_handle(table=i).inset_prompt(old_data) + + +sqlite_handle = SqliteHandle +if __name__ == '__main__': + pass \ No newline at end of file