GetInt32 with a count() column
Hi,
I am having trouble with retrieving a Count(*) column from a MySqlDataReader
when I call reader.GetInt32(0), it throws a System.InvalidCastException.
if I get the value back with reader.GetString(0) it returns "2" which is the correct count.
Is this a known bug with the MySqlConnector (I am using the latest stable versions of everything as of this post). Obviously there is an easy workaround which is to use int.parse()
--- Tim
Subject
Written By
Posted
GetInt32 with a count() column
January 19, 2005 06:26AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.