[求助],插入数据库的代码问题!
第 1 行: ',' 附近有语法错误。strsql = "insert into [users_reg]([qiye_name], [address], [province], [city], [faren], [faren_id], [money], [tel1], [tex1], [contact_person], [sex], [tel2], [u_id],[tex2], [e_mail], [login_num], [pwd], [reg_tim],[log_tim], [is_able], [is_edit], [is_pass])values"
strsql += " ('" & Trim(qiye_name.Text) & "','" & Trim(address.Text) & "','" & province.SelectedItem.Text.ToString & "','" & Trim(city.Text) & "','" & Trim(faren.Text) & "','" & Trim(faren_id.Text) & "','" & Trim(money.Text) & "','" & Trim(tel1.Text) & "'"
strsql += ",'" & Trim(tex1.Text) & "','" & Trim(contact_person.Text) & "','" & get_sex() & "','" & Trim(tel2.Text) & "','" & Trim(u_id.Text) & "','" & Trim(tex2.Text) & "','" & Trim(e_mail.Text) & "','" & Trim(login_num.Text) & "','" & Trim(pwd.Text) & "',getdate(),getdate(),0,0,0)"
conn.RunSql(strsql)
我找了半天没有找到那有问题,大家帮帮忙了!快郁闷死呀!
strsql += " ('" & Trim(qiye_name.Text) & "','" & Trim(address.Text) & "','" & province.SelectedItem.Text.ToString & "','" & Trim(city.Text) & "','" & Trim(faren.Text) & "','" & Trim(faren_id.Text) & "','" & Trim(money.Text) & "','" & Trim(tel1.Text) & "'"
strsql += ",'" & Trim(tex1.Text) & "','" & Trim(contact_person.Text) & "','" & get_sex() & "','" & Trim(tel2.Text) & "','" & Trim(u_id.Text) & "','" & Trim(tex2.Text) & "','" & Trim(e_mail.Text) & "','" & Trim(login_num.Text) & "','" & Trim(pwd.Text) & "',getdate(),getdate(),0,0,0)"
conn.RunSql(strsql)
我找了半天没有找到那有问题,大家帮帮忙了!快郁闷死呀!
[此贴子已经被作者于2007-6-25 10:57:28编辑过]