Use of SQL Server 2000 as a data source for AUXWODBC - A4000018 - 14 March 2001

 

In order to have any hope of using this product with AUXWODBC you need to download fix K4000031.

It is currently very difficult to use SQL Server 2000 as a data source for AUXWODBC. In particular databases with date and time fields will pose considerable problems: SQL Server 2000 does not support a date or time data type, only a combined timestamp type. What makes this more serious is that the ODBC driver for SQL Server 2000 refuses to convert such fields to dates or times (it generates the error "Optional Feature not implemented"), and, incredibly, there is no function to extract the date or time part of such a field into a single column, or to convert a date or time into a number of days or seconds since a fixed date. It is only possible to extract the various individual components (year, month,day etc) into separate columns. As a a result AUXWODBC cannot currently access data in tables with date or time fields from SQL Server 2000.

Currently the only work-around for this problem is to use the timestamps=1 option, to combine date and time fields with matching roles into a single timestamp field on the SQL database. Note that for this work-around to be effective all date and time fields have to be in matching pairs (using the same non blank role) and adjacent to each other in the DP4 data record. In addition you may run into problems if there are date and time indexes on the database, as in some cases a spurious system error 305 may be generated (See K4000031). The only cure in this case is to make sure that both the date and time components are always used in the index, and the relative key precedences follow the order of the fields within the data record.

We currently think that Microsoft will have to fix this limitation in their ODBC driver for SQL Server 2000, and for the time being do not propose to enhance AUXWODBC to work with this wonderful piece of software. If it is necessary to enhance AUXWODBC we anticipate that at least several days work will be required, as an additional buffer and translation layer will have to be added to convert date between the format expected by DP4 and the data returned by SQL Server 2000.