New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Selecting a Timestamp(3) column returns incorrect milliseconds. #5

Closed
escheie opened this Issue Aug 13, 2015 · 0 comments

Comments

Projects
None yet
1 participant
@escheie
Member

escheie commented Aug 13, 2015

Issue with reading timestamp (3) I extract same data via teradata and pyodbc , 3rd column has type timestamp(3)
_____________________ here is my code _______________

import teradata
import pyodbc

udaExec = teradata.UdaExec (appName="DfToTera", version="1.0",logConsole=False,logRetention=0,configureLogging=False)
session = udaExec.connect(method="odbc", system="oneview",username="xxx", password="xxx",database="ud183")

for row in session.execute("""SELECT * from test4 order by 1"""):
print(row[2])

conn = pyodbc.connect('DRIVER={Teradata};DBCNAME=oneview;UID=xxx;PWD=xxx;database=ud183',autocommit=True)

for row in conn.execute("""SELECT * from test4 order by 1"""):
print(row[2])


results below when selecting using teradata connection shows incorrect decimal point , any ideas ?

In[292]: for row in session.execute("""SELECT * from test4 order by 1"""):

    print(row[2])

2015-07-01 12:18:32.000673

2013-09-10 10:34:08.000260

2014-09-18 15:27:31.000490

2014-06-25 11:59:59.000873

2015-01-16 17:30:43.000900

In[293]: for row in conn.execute("""SELECT * from test4 order by 1"""):

    print(row[2])

2015-07-01 12:18:32.673000

2013-09-10 10:34:08.260000

2014-09-18 15:27:31.490000

2014-06-25 11:59:59.873000

2015-01-16 17:30:43.900000

@escheie escheie added the bug label Aug 13, 2015

@escheie escheie self-assigned this Aug 13, 2015

@escheie escheie added this to the 15.10.00.04 milestone Aug 13, 2015

@escheie escheie closed this in af07eb6 Aug 13, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment