Fixed bug

This commit is contained in:
SimpleArt
2020-11-16 12:27:15 -05:00
parent 2171576a99
commit add236836c

View File

@ -107,13 +107,13 @@ class SQL_Database:
elif type(db_config_list[i]) not in self.sql_types:
db_config_list[i] = str(db_config_list[i])
# For some reason it has to be in var = array(tuple()) form
db_config_list = [tuple(db_config_list)]
# Create sql query structure
sql = f"""INSERT INTO config ({''',
'''.join(ga.__dict__.keys())}) VALUES({(',?'*len(db_config_list))[1:]}) """
# For some reason it has to be in var = array(tuple()) form
db_config_list = [tuple(db_config_list)]
# Execute sql query
cur = self.conn.cursor()
cur.executemany(sql, db_config_list)