pyodbc
pyodbc copied to clipboard
Expose sql_type for columns in resultset #167
@jstastny-cz This looks clean, but I'm wary about adding something to the interface without knowing what someone would do with it. I'm not sure how one would make use of this information. What was the use case for this? Thanks.
@mkleehammer Hello, we used pyodbc for ODBC interface/driver tests. What we needed to do was to check the actual SQL data type returned by the driver.
If I understand the PR correctly, then we have the same use case. I am using pyodbc to generate SQL Server create tables DDL based on the result set. If the actual SQL type is returned, we can create exact DDL. Right now we are creating approximate DDL.
Yes please! We have a use case that requires us to know the actual SQL type behind the column. We have been unable to come up with a clean workaround.