博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
拼SQL语句执行更新
阅读量:4045 次
发布时间:2019-05-24

本文共 738 字,大约阅读时间需要 2 分钟。

2014年3月29日14:00:00

拼SQL语句执行更新

try  	{  		CString sInsert; 		CString str;		sInsert.Format(_T("update SEXIT2013090100007 set transfermark=transfermark+8 where "));		sInsert+=_T("programstarttime='");		sInsert+=aRec.m_dtProgramStartTime.Format();		str.Format(_T("' and recordno=%d"),aRec.m_nRecordNo);		sInsert+=str;		str.Format(_T(" and exitlane=%d"),aRec.m_nExitLane);		sInsert+=str;		sInsert+=_T(" and exittime='");		sInsert+=aRec.m_dtExitTime.Format();		str.Format(_T("' and cancelrecord=%d"),aRec.m_nCancelRecord);		sInsert+=str;		pStationConnection->Execute((_bstr_t)sInsert,NULL,adCmdText);  	}catch (_com_error &e)  	{  		CString sInfo;  		sInfo.Format(_T("更新数据失败:%s"),e.ErrorMessage());  		DBG_AfxMessageBox(sInfo);  		exit(-1);  	}

转载地址:http://ajwci.baihongyu.com/

你可能感兴趣的文章
mint/ubuntu安装搜狗输入法
查看>>
C++动态申请数组和参数传递问题
查看>>
opencv学习——在MFC中读取和显示图像
查看>>
Matlab与CUDA C的混合编程配置出现的问题及解决方案
查看>>
如何将PaperDownloader下载的文献存放到任意位置
查看>>
C/C++中关于动态生成一维数组和二维数组的学习
查看>>
JVM最简生存指南
查看>>
Java的对象驻留
查看>>
JVM并发机制探讨—内存模型、内存可见性和指令重排序
查看>>
如何构建高扩展性网站
查看>>
持续可用与CAP理论 – 一个系统开发者的观点
查看>>
nginx+tomcat+memcached (msm)实现 session同步复制
查看>>
c++字符数组和字符指针区别以及str***函数
查看>>
c++类的操作符重载注意事项
查看>>
c++模板与泛型编程
查看>>
WAV文件解析
查看>>
WPF中PATH使用AI导出SVG的方法
查看>>
WPF UI&控件免费开源库
查看>>
QT打开项目提示no valid settings file could be found
查看>>
Win10+VS+ESP32环境搭建
查看>>