How to retrieve attribute of type Time without time zone from postgreSQL?
-
Hello, I am writing one simple C# .NET application in which I have to use some values retrieved from the database. But when I try to retrieve value of attribute of type Time without time zone it generates following exception {"Index was outside the bounds of the array."} System.Exception {System.IndexOutOfRangeException} This happens only when I try to retrive this type .. for other attribute types, it is working properly. My code is ... //-------------------------------------------------------------- String myQuery = "Select starttime from tblecture"; OdbcCommand myCommand = new System.Data.Odbc.OdbcCommand(myQuery, conn); OdbcDataReader dataReader = myCommand.ExecuteReader(); while(dataReader.Read())//Exception being generated on this line { //code to use database info } //-------------------------------------------------------------- Schema of tblecture table is: Table "public.tblecture" Column | Type | Modifiers -----------------+------------------------+---------------------------- lectureid | integer | not null starttime | time without time zone | Thanks, Regards, Kranti