请求未执行:
mycmd = new MySqlCommand();
mycmd.CommandText = "INSERT INTRO 'users' (userid, username, password, ipaddr, port, channel, inbox, inboxadm, access, other) VALUES (NULL, 'username2', 'password2', NULL, NULL, 'channel2', NULL, NULL, 'access2', NULL);";
mycmd.Connection = mconnection;
mycmd.Parameters.AddWithValue("username2", message.Login);
mycmd.Parameters.AddWithValue("password2", message.Password);
mycmd.Parameters.AddWithValue("channel2", "channel");
mycmd.Parameters.AddWithValue("access2", 0);
mycmd.CommandType = CommandType.Text;
mycmd.ExecuteNonQuery();
帮助查找和纠正请求中的错误。
示例 phpmyadmin SQL 查询:
INSERT INTO `shachat`.`users` (`userid`, `username`, `password`, `ipaddr`, `port`, `channel`, `inbox`, `inboxadm`, `access`, `other`) VALUES (NULL, 'myacc', 'mypass', NULL, NULL, 'administratorY', NULL, NULL, '9', NULL);