mirror of
https://github.com/donaldzou/WGDashboard
synced 2025-02-26 05:58:47 +00:00
Remove with sqldb
in SQL Select
This commit is contained in:
parent
e0bc6a10d0
commit
bf6f58eb5e
@ -1638,13 +1638,13 @@ sqldb.isolation_level = None
|
|||||||
cursor = sqldb.cursor()
|
cursor = sqldb.cursor()
|
||||||
|
|
||||||
def sqlSelect(statement: str, paramters: tuple = ()) -> sqlite3.Cursor:
|
def sqlSelect(statement: str, paramters: tuple = ()) -> sqlite3.Cursor:
|
||||||
with sqldb:
|
try:
|
||||||
try:
|
cursor = sqldb.cursor()
|
||||||
cursor = sqldb.cursor()
|
return cursor.execute(statement, paramters)
|
||||||
return cursor.execute(statement, paramters)
|
except Exception as e:
|
||||||
except Exception as e:
|
print("[WGDashboard] SQLite Error:" + str(error) + " | Statement: " + statement)
|
||||||
print("[WGDashboard] SQLite Error:" + str(error) + " | Statement: " + statement)
|
return []
|
||||||
return []
|
|
||||||
|
|
||||||
|
|
||||||
def sqlUpdate(statement: str, paramters: tuple = ()) -> sqlite3.Cursor:
|
def sqlUpdate(statement: str, paramters: tuple = ()) -> sqlite3.Cursor:
|
||||||
|
Loading…
Reference in New Issue
Block a user