日期:2014-05-19  浏览次数:20431 次

两次text.Delete();之后就不能进行m_pConnection->Excute();相数据库插入数据;
CString   text;
text.Delete(0,500);
text.Delete(500,3764);   //text.GetLength()=4764

str= "insert   into   big_number   values(1, ' "+text1+ " ') ";
m_pConnection-> Execute(_bstr_t(str),&RecordsAffected,adCmdText);
问题:用了两次delete之后就不能执行m_pConnection-> Execute();
        而text.Delete(0,4500)之后却能执行m_pConnection-> Execute();
不知道是什么原因?

------解决方案--------------------
看看str的值
------解决方案--------------------
帮你顶。。。。。