Open fpauser opened 7 years ago
Thanks for bringing this to our attention @fpauser. We will investigate further, but I would not be surprised if this column type is not supported by the Erlang ODBC library.
More about datetimeoffset
:
Defines a date that is combined with a time of a day that has time zone awareness and is based on a 24-hour clock.
More info on the type on Microsoft Docs.
Seems like odbc-support for current sqlserver features is quite limited. Not being able to query datetimeoffset
columns is a showstopper for me.
Yeah, the Erland ODBC application has very limited support for non-standard column types. You would need to either patch Erlang OTP or write your own driver to use instead of ODBC. The latter is what https://github.com/livehelpnow/tds tried but that project hasn't been maintained in a long time, which speaks to the complexity of the task.
We unfortunately have no plans to undertake either of these pieces of work but we'll gladly cooperate with anyone who is willing to do so.
I have opened up this issue on the Erlang/OTP bug board. Will try and fix it myself hopefully with a bit of guidance from the OTP maintainers.
C Data Type Struct for datetimeoffset: https://docs.microsoft.com/en-us/sql/relational-databases/native-client-odbc-date-time/data-type-support-for-odbc-date-and-time-improvements
hi, i just stumbled upon this issue. FIY, datetimeoffset not supported on python odbc driver either so it's probably not erlang specific :)
Querying a table with a
datetimeoffset
field gives an error: 'Column type not supported'. Also tested directly with:odbc
, error persists:Is it really
:odbc.sql_query
that does not supportdatetimeoffset
?