You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nzpy throws error when using python datetime type as placeholder . For e.g:
import nzpy
from datetime import ( datetime as Datetime)
conn = nzpy.connect(user="admin", password="password",host='localhost', port=5480, database="db1", securityLevel=0,logLevel=0, logOptions=nzpy.LogOptions.Logfile)
with conn.cursor() as cursor:
v = Datetime(2001, 2, 3, 4, 5, 6, 170000)
cursor.execute("select ? as f1",(v,))
for i in cursor.fetchall():
print(i)
Traceback (most recent call last):
File "run4.py", line 11, in <module>
cursor.execute("select ? as f1",(v,))
File "/usr/local/lib/python3.6/site-packages/nzpy-1.0-py3.6.egg/nzpy/core.py", line 850, in execute
self._c.execute(self, operation, args)
File "/usr/local/lib/python3.6/site-packages/nzpy-1.0-py3.6.egg/nzpy/core.py", line 1827, in execute
raise ProgrammingError(self.error)
nzpy.core.ProgrammingError: ERROR: 'select 2001-02-03 04:05:06.170000 as f1'
error ^ found "04" (at char 19) expecting a keyword
The text was updated successfully, but these errors were encountered:
Nzpy throws error when using python datetime type as placeholder . For e.g:
The text was updated successfully, but these errors were encountered: