Skip to content

Support DATETIMEOFFSET #25

@ploeh

Description

@ploeh

This seems like a great library, but some version (I forget which one) of SQL Server introduced the DATETIMEOFFSET column time, and if one tries to query a table with such a column, an exception is thrown.

Steps to reproduce

Create a tabel as follows:

CREATE TABLE [dbo].[DateTimeOffsetRepro] ([Date] DATETIMEOFFSET NOT NULL)

Insert some data into it; e.g.

INSERT INTO DateTimeOffsetRepro VALUES ('2019-05-08T18:24:41-06:00')

In GHCi, create a connection conn to the database, and attempt to use query to read the data:

Prelude Database.ODBC.SQLServer> query conn "SELECT * FROM DateTimeOffsetRepro"
*** Exception: UnknownDataType "getData" (-155)

Expected result

The data from the database is printed in GHCi.

Actual result

An exception is thrown, as shown above.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions