Page 1 of 1

Exception: GetTimeSpan() String was not recognized as a va

Posted: Tue 27 Mar 2012 10:06
by goethals.f
Hello,

Today I got the exception "String was not recognized as a valid TimeSpan" when trying to read an oracle column which is specified as

TIME_ELAPSED INTERVAL DAY(2) TO SECOND(6)


When debuging my code:

The following statement

Code: Select all

tmpResultOracleReader[10] 


shows in my watch-window that this is an object {System.Timespan}, and it holds the correct values (days, hours, seconds, etc...)
so this seems OK

But when i try the following code

Code: Select all

tmpResultOracleReader.GetTimeSpan(10)
then my watch-window shows the System.formatException ("String was not recognized as a valid TimeSpan.)


--> why does the .GetTimeSpan(...) method of the Devart.Data.Oracle.OracleDataReader object doesn't return a correct timestamp, but the simple indexer does ???

[/code]

thx
Fred

Posted: Wed 28 Mar 2012 13:24
by Pinturiccio
We have reproduced the issue. We will investigate it and notify you about the results as soon as possible.

Posted: Tue 03 Apr 2012 15:32
by Pinturiccio
We have fixed the bug with using the OracleDataReader.GetTimeSpan method for INTERVAL DAY TO SECOND column. We will post here when the corresponding build of dotConnect for Oracle is available for download.

Posted: Fri 13 Apr 2012 08:08
by Pinturiccio
The new build of dotConnect for Oracle 6.80.341 is available for download now!
It can be downloaded from http://www.devart.com/dotconnect/oracle/download.html (trial version) or from Registered Users' Area (for users with valid subscription only).
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=23886