@@ -103,6 +105,11 @@ class TDengineCursor(object):
...
@@ -103,6 +105,11 @@ class TDengineCursor(object):
defexecute(self,operation,params=None):
defexecute(self,operation,params=None):
"""Prepare and execute a database operation (query or command).
"""Prepare and execute a database operation (query or command).
"""
"""
ifthreading.get_ident()!=self._threadId:
info="Cursor execute:Thread ID not match,creater:"+str(self._threadId)+" caller:"+str(threading.get_ident())
print(info)
returnNone
ifnotoperation:
ifnotoperation:
returnNone
returnNone
...
@@ -188,6 +195,10 @@ class TDengineCursor(object):
...
@@ -188,6 +195,10 @@ class TDengineCursor(object):
deffetchall(self):
deffetchall(self):
"""Fetch all (remaining) rows of a query result, returning them as a sequence of sequences (e.g. a list of tuples). Note that the cursor's arraysize attribute can affect the performance of this operation.
"""Fetch all (remaining) rows of a query result, returning them as a sequence of sequences (e.g. a list of tuples). Note that the cursor's arraysize attribute can affect the performance of this operation.
"""
"""
ifthreading.get_ident()!=self._threadId:
info="Cursor fetchall:Thread ID not match,creater:"+str(self._threadId)+" caller:"+str(threading.get_ident())
print(info)
returnNone
ifself._resultisNoneorself._fieldsisNone:
ifself._resultisNoneorself._fieldsisNone:
raiseOperationalError("Invalid use of fetchall")
raiseOperationalError("Invalid use of fetchall")
...
@@ -232,6 +243,11 @@ class TDengineCursor(object):
...
@@ -232,6 +243,11 @@ class TDengineCursor(object):
def_handle_result(self):
def_handle_result(self):
"""Handle the return result from query.
"""Handle the return result from query.
"""
"""
ifthreading.get_ident()!=self._threadId:
info="Cursor handleresult:Thread ID not match,creater:"+str(self._threadId)+" caller:"+str(threading.get_ident())