manhsakura
New Member
\[code\]con.Open();SqlCommand cmd=new SqlCommand("INSERT INTO user(Firstname,Lastname,Email,Pass,Type) values(@first,@last,@email,@pass,@type)",con);cmd.Parameters.Add("@first",SqlDbType.NVarChar).Value = http://stackoverflow.com/questions/14537214/txtfirst.Text;cmd.Parameters.Add("@last",SqlDbType.NVarChar).Value = http://stackoverflow.com/questions/14537214/txtlast.Text;cmd.Parameters.Add("@email",SqlDbType.NVarChar).Value = http://stackoverflow.com/questions/14537214/txtemail.Text;cmd.Parameters.Add("@pass",SqlDbType.NVarChar).Value = http://stackoverflow.com/questions/14537214/txtpass.Text;cmd.Parameters.Add("@type",SqlDbType.NVarChar).Value = "http://stackoverflow.com/questions/14537214/customer";cmd.ExecuteNonQuery();con.Close();\[/code\]what is the problem with my syntax it says "Incorrect syntax near the keyword 'user'."