While processing the following code am getting some error.
queryCommand= "select user_name,user_lastname,user_address from usertable"
objODBCDataReader = dbconObject.GetDataReader(queryCommand)
If objODBCDataReader.HasRows = True Then
Dim userName = objODBCDataReader.Item("user_name").ToString() 'here it throws error as Arithmetic operation resulted in an overflow
End If
GetDataReader
is a method that that will accept the query as string and return the result as Datareader
.
let me know why this error is occurring while assigning a string value to a string variable?
am using
VisualStudio 2012
mysql 5.0
odbc driver 3.51
64 bit os
In your IF statement you are TESTING to see if ROWS exist,
At this point you have not READ any data?