mtadayon / pypyodbc

Automatically exported from code.google.com/p/pypyodbc
0 stars 0 forks source link

pypyodbc doesn't support the MSSQL datetimeoffset column type. #56

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Running a select statement on a MSSQL Server (2008 or later) table 
containing a column of type datetimeoffset.
2.
3.

What is the expected output? What do you see instead?

Expected output is for pypyodbc to get the row values for the datetimeoffset 
columns and represent them as python datetime objects.

Actual output is that when calling the execute() method on a cursor passing in 
a select statement string which is getting a datetimeoffset column, a KeyError 
exception is thrown with value of '-155' as the SQL data type value for 
datetimeoffset (-155) is not defined or handled in pypyodbc.

What version of the product are you using? On what operating system?

pypyodbc V1.3.3, Python V2.7.6 and Microsoft SQL Server 2014 Express x64 both 
running on  Windows 7 SP1 x64.

Please provide any additional information below.

I've fixed the problem myself and attached a modified version of pypyodbc 
V1.3.3 containing the fix to this ticket.

Original issue reported on code.google.com by AViewFro...@gmail.com on 27 Oct 2014 at 12:49

Attachments: