给Access数据库添加数据,但是提示insert into语法错误
这是我拿messegebox打出来insertinto语句的信息这是提示的错误信息。源码是hr=m_pConnection->Open(("Provider=Micros...
这是我拿messegebox打出来insert into语句的信息
这是提示的错误信息。
源码是hr=m_pConnection->Open(("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=F:\\rtxclentsdk20111formal.exe安装\\Database2.mdb"),"","",adModeUnknown); MessageBox( "insert into Database2(Theme,Content,Time,TiXing,ZhouYi,ZhouEr,ZhouSan,ZhouSi,ZhouWu,ZhouLiu,ZhouRi) values('"+m_EDIT1+"','"+m_NeiRong+"','"+Dingshi+"','"+Lcheck1+"','"+LZhouYi+"','"+LZhouEr+"','"+LZhouSan+"','"+LZhouSi+"','"+LZhouWu+"','"+LZhouLiu+"','"+LZhouRi+"')", "Info", MB_OK ); m_pConnection->Execute(_bstr_t("insert into Database2(Theme,Content,Time,TiXing,ZhouYi,ZhouEr,ZhouSan,ZhouSi,ZhouWu,ZhouLiu,ZhouRi) values('"+m_EDIT1+"','"+m_NeiRong+"','"+Dingshi+"','"+Lcheck1+"','"+LZhouYi+"','"+LZhouEr+"','"+LZhouSan+"','"+LZhouSi+"','"+LZhouWu+"','"+LZhouLiu+"','"+LZhouRi+"')"),NULL ,adCmdText);
哪位大神给看一下,先谢了。 展开
这是提示的错误信息。
源码是hr=m_pConnection->Open(("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=F:\\rtxclentsdk20111formal.exe安装\\Database2.mdb"),"","",adModeUnknown); MessageBox( "insert into Database2(Theme,Content,Time,TiXing,ZhouYi,ZhouEr,ZhouSan,ZhouSi,ZhouWu,ZhouLiu,ZhouRi) values('"+m_EDIT1+"','"+m_NeiRong+"','"+Dingshi+"','"+Lcheck1+"','"+LZhouYi+"','"+LZhouEr+"','"+LZhouSan+"','"+LZhouSi+"','"+LZhouWu+"','"+LZhouLiu+"','"+LZhouRi+"')", "Info", MB_OK ); m_pConnection->Execute(_bstr_t("insert into Database2(Theme,Content,Time,TiXing,ZhouYi,ZhouEr,ZhouSan,ZhouSi,ZhouWu,ZhouLiu,ZhouRi) values('"+m_EDIT1+"','"+m_NeiRong+"','"+Dingshi+"','"+Lcheck1+"','"+LZhouYi+"','"+LZhouEr+"','"+LZhouSan+"','"+LZhouSi+"','"+LZhouWu+"','"+LZhouLiu+"','"+LZhouRi+"')"),NULL ,adCmdText);
哪位大神给看一下,先谢了。 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询