Hello - I've a problem with the mysql connector for c#.
My code-example:
using (MySqlCommand mySQL_CMD = new MySqlCommand("UPDATE `Table` SET `Value`=?Value WHERE `ID`=?ID", Connection))
{
mySQL_CMD.Parameters.Add("?ID", MySqlDbType.UInt32).Value = 5;
mySQL_CMD.Parameters.Add("?Value", MySqlDbType.UInt32).Value = 5;
await mySQL_CMD.ExecuteNonQueryAsync();
}
after calling this functions many times my memory increased and my application crashed i've tried to use "mySQL_CMD.Parameters.clear()" because memory profiler tells me there are many mysqlparameter instances ... but no success.
So i dont know how to use the lib correct to not create a big memory leak :(
I hope someone can help me.
Greetz
My code-example:
using (MySqlCommand mySQL_CMD = new MySqlCommand("UPDATE `Table` SET `Value`=?Value WHERE `ID`=?ID", Connection))
{
mySQL_CMD.Parameters.Add("?ID", MySqlDbType.UInt32).Value = 5;
mySQL_CMD.Parameters.Add("?Value", MySqlDbType.UInt32).Value = 5;
await mySQL_CMD.ExecuteNonQueryAsync();
}
after calling this functions many times my memory increased and my application crashed i've tried to use "mySQL_CMD.Parameters.clear()" because memory profiler tells me there are many mysqlparameter instances ... but no success.
So i dont know how to use the lib correct to not create a big memory leak :(
I hope someone can help me.
Greetz