update table1 set field1=:xyb where id=1
请问如何页面中填写的数据赋给xyb参数
如:xyb=text1.text;
SqlCommand command=new SqlCommand("update table1 set field1=:xyb where id=1",conn)
command.Parameters.add(text1.text)
SqlCommand myCommand = new SqlCommand("update table1 set field1=@xyz where id=1",conn);
myCommand.Parameters.Add("@xyz", SqlDbType.VarChar,80).Value =text1.text;
说的很对,不同的方式,要用不同的符号,在ole中,用?。