Input string was not in a correct format
Posted: Wed 10 Nov 2004 19:29
Using MySql 4.1 and MySqlDirect version 1.80.9.0
An ExecuteScalar command that works perfectly with MySql 4.0.13 is now giving me an exception when I try and connect to my new 4.1 database.
Dim strSql As String = "SELECT trialby FROM tblTrialBy"
Dim sqlCmd As MySqlCommand = New MySqlCommand(strSql, MySqlConn)
sqlCmd.ExecuteScalar()
Exception thrown:
System.FormatException: Input string was not in a correct format.
I'm confused, its just simple select statement.
An ExecuteScalar command that works perfectly with MySql 4.0.13 is now giving me an exception when I try and connect to my new 4.1 database.
Dim strSql As String = "SELECT trialby FROM tblTrialBy"
Dim sqlCmd As MySqlCommand = New MySqlCommand(strSql, MySqlConn)
sqlCmd.ExecuteScalar()
Exception thrown:
System.FormatException: Input string was not in a correct format.
I'm confused, its just simple select statement.