sa 188.8.131.523 DataTypeEnum adDBTime returns 145 instead of 134.
Provider = SAOLEDB.16 Error Description = Multiple-step operation generated errors. Check each status value.
Any suggestions? Thanks
asked 29 May '15, 13:45
I assume you meant to say 135 (adDBTimeStamp) instead of 145 (which is not defined).
In the database server Date, Time, DateTime and TimeStamp are represented as timestamps (storage wise) and through the SQL Anywhere .Net API those SADbTypes will be mapped to System.DateTime. See the SADbType enumeration page for the reference on that. There should be a similar mapping for when you use the OleDB driver instead.
The fact that your are not using the ADO.Net provider could be causing some of the issues you are seeing there. To use an OleDB driver with ADO.Net you must go through a generic ADO-to-OLE/DB bridge layer and mappings may not work as expect in all cases. I do recommend testing with the SA.Net Data Provider to verify if the issue only exists when going through that bridge or is more general than that.
But if you are actually seeing 145 that may be because the OLE/DB will map our timestamps to DBTYPE_DBTIME2 (which would be correct for that driver) ... and the bridge is unable to convert that for some reason.
This OLE DB data type seems to have been introduced circa SQL SERVER 2008 and I suspect the ADO-to-OLEDB bridge (System.Data.Oledb) knows nothing about it (since it is much older technology and probably unchanged since long before that time.
FWIW there was a change of behavior with Version 16 where we can no longer support Borland Delphi with that driver because of the required introduction of this new datatype.
answered 29 May '15, 18:18
Nick Elson S...