List:MySQL and .NET« Previous MessageNext Message »
From:Reggie Burnett Date:March 15 2005 3:44pm
Subject:Re: Using MySQL dates in vb.net using the ODBC connector
View as plain text  
Jan

If you are getting back a MySqlDateTime object then you are not using
Connector/ODBC.  Can you be more clear as to which connector product you
are using?

jan.deklerck@stripped wrote:

>Hi all,
>
>I try to read dates from a MySQL database.
>My application is in VB.Net, I use the ODBC connector version 3.51.
>
>My code :
>
>With ReturnedDataReader
>    Private mCreatedOn As Date
>    Try
>        mCreatedOn = .GetDateTime(4)  'This worked fine with MS Access and 
>SQL Server
>    Catch ex As Exception
>        Try
>            ' datetimes are being returned as a MySqlDateTime
>What should I do here to retrieve a valid DateTime from MySQL ? I have no 
>clue ... 
>        Catch ex2 As Exception
>            mCreatedOn = Date.MinValue
>        End Try
>    End Try
>
>Thanks for any help offered !
>
>Jan
>  
>

-- 
Reggie Burnett, Software Developer
MySQL Inc, http://www.mysql.com

MySQL Users Conference (Santa Clara CA, 18-21 April 2005)
Early registration until February 28: http://www.mysqluc.com/


Thread
Using MySQL dates in vb.net using the ODBC connectorjan.deklerck11 Mar
  • Re: Using MySQL dates in vb.net using the ODBC connectorReggie Burnett15 Mar
RE: Using MySQL dates in vb.net using the ODBC connectorKevin Turner11 Mar