Problems with DATETIME fields and Informix ODBC
Posted in 1999
Topics: Stored Procedures & SPL, Connectivity: ODBC / JDBC / .NET
Hi, i have several problems with DATETIME fields, when i want to access a DATETIME field via ODBC using Informix CLI 2.50.TD2 on Windows NT 4.0 SP 3+4 . When I use for example SCO Vision Gold (a utility for sending SQL commands and display tables) and try to view a a field of type DATETIME TIME TO SECOND with value 11:22:33 it always displays this field as 11.11.1111 11:22:33 . The date portion is always set to 11.11.1111 and the time portion shows the correct time value. I have played with the DBTIME, GL_DATETIME and CL_DATETIME fields in the setnet utility without success. If i use an other ODBC driver like the SCO SQL retreiver a DATETIME field is always displayed correctly. I can't easily replace Informix CLI because I use unify vision for building an application and vision seems to use Informix Cli for it's native drivers. Vision has also problems to access DATETIME fields. Are there known problems with Informix CLI or is there an trick to get this working ?. Thanks for any help Uli -- Ulrich Eckhardt Tr@nscom GbR http://people.frankfurt.netsurf.de/uli http://www.transcom.de Lagerstraße 11-15 A8 64807 Dieburg Germany
Ulrich Eckhardt wrote: > i have several problems with DATETIME fields, when i want to > access a DATETIME field via ODBC using Informix CLI 2.50.TD2 > on Windows NT 4.0 SP 3+4 . > > When I use for example SCO Vision Gold (a utility for sending > SQL commands and display tables) and try to view a > a field of type DATETIME TIME TO SECOND with value 11:22:33 > it always displays this field as 11.11.1111 11:22:33 . > The date portion is always set to 11.11.1111 and the time > portion shows the correct time value. > > I have played with the DBTIME, GL_DATETIME and CL_DATETIME > fields in the setnet utility without success. > > If i use an other ODBC driver like the SCO SQL retreiver > a DATETIME field is always displayed correctly. > > I can't easily replace Informix CLI because I use > unify vision for building an application and vision > seems to use Informix Cli for it's native drivers. Vision > has also problems to access DATETIME fields. > > Are there known problems with Informix CLI or is there > an trick to get this working ?. > > Thanks for any help > Uli > -- > Ulrich Eckhardt Tr@nscom GbR > http://people.frankfurt.netsurf.de/uli http://www.transcom.de > Lagerstraße 11-15 A8 > 64807 Dieburg Germany SCO Vision Gold is an application that is part of SCO SQL-Retriever. Its results are sometimes unpredictable. If you can produce the same (incorrect) results in something like MS-Access, I will happily look at the problem. However, you say that: > If i use an other ODBC driver like the SCO SQL retreiver > a DATETIME field is always displayed correctly. so it seems our driver is correct. I think I may have not understood your explanation correctly and may have confused your use of our ODBC driver with the Informix CLI. Sometimes, an ODBC driver should return a date in the full ODBC date format and it is the responsibility of the ODBC driver to format the date: some applications allow you to do this, others do not. Either way, if you would like to contact me with further details, I will be happy to look at the problem. Allan Gould SCO CID Support, Leeds, UK (allang at sco dot com) (Please remove anti-spam measures if replying)
Allan Gould wrote: > Ulrich Eckhardt wrote: > > i have several problems with DATETIME fields, when i want to > > access a DATETIME field via ODBC using Informix CLI 2.50.TD2 > > on Windows NT 4.0 SP 3+4 . > > When I use for example SCO Vision Gold (a utility for sending > > SQL commands and display tables) and try to view a > > a field of type DATETIME TIME TO SECOND with value 11:22:33 > > it always displays this field as 11.11.1111 11:22:33 . > > The date portion is always set to 11.11.1111 and the time > > portion shows the correct time value. [..] > > Are there known problems with Informix CLI or is there > > an trick to get this working ?. > > SCO Vision Gold is an application that is part of SCO SQL-Retriever. > Its results are sometimes unpredictable. If you can produce the same > (incorrect) results in something like MS-Access, I will happily look at > the problem. However, you say that: > > If i use an other ODBC driver like the SCO SQL retreiver > > a DATETIME field is always displayed correctly. > so it seems our driver is correct. I think I may have not understood > your explanation correctly and may have confused your use of our ODBC > driver with the Informix CLI. Hi, there is no problem with SCO Vision Gold or SQL Retreiver. I had used it as example, that i have a working solution. The problems i have seems comming from the Informix CLI ODBC driver. Uli -- Ulrich Eckhardt Tr@nscom GbR http://people.frankfurt.netsurf.de/uli http://www.transcom.de Lagerstraße 11-15 A8 64807 Dieburg Germany