When I try to insert a string value using mdmysql.Parameters.AddWithValue it generates an input format string exception. Following is the code which produces the error:
cmdmysql.Parameters.AddWithValue("@p_mode", MySqlDbType.VarChar).Value = "ccc";
I tried with varchar, string, text but nothing is working. Also if I put null in place of "ccc" then the record gets inserted into the table. The variable type for p_mode in table is varchar. What is the reason for this exception?