problem with mySql-Connector .Net - 1.0.4 - parameter
Posted by:
info
Date: February 03, 2005 01:12AM
hey guys,
i use c#, vs studio .net, mySql and the ByteFX-DataProvider so long. It works great, there are no problems. Now i would like to change my application using the new MySql-Connector for .Net ( 1.0.4 ), but there is a problem...
MySqlParameter p1 = new MySqlParameter("@p1", MySqlDbType.Int32);
MySqlParameter p2 = new MySqlParameter("@p2", MySqlDbType.String);
p1.Value = adressID;
p2.Value = comboBox1.SelectedText;
myCmd.Parameters.Add(p1);
myCmd.Parameters.Add(p2);
myCmd.CommandText = "INSERT INTO mandant (AdressID, Waehrung) VALUES (@p1, @p2)";
myCmd.ExecuteNonQuery();
So far, this code works great. Now i get the exception "AdressID cannot be null", but the p1.Value isnĀ“t null...
Does anyone know why???
thx for any answer
jlo - germany
Subject
Written By
Posted
problem with mySql-Connector .Net - 1.0.4 - parameter
February 03, 2005 01:12AM
February 03, 2005 01:35AM
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.