补充了一下,用ado+sql语句的形式搞定了:
//CString tmp ("select * from Patient where PatLogicID = 0x");
CString tmp ("DELETE FROM Patient WHERE PatLogicID = 0x");
int i;
for ( i = 0; i < 16; ++i )
{
CString t_sAdd;
t_sAdd.Format( "%x", (BYTE)t_sPatLogicID.GetAt(i) );
if ( t_sAdd.GetLength() == 1 )
{
t_sAdd = "0" + t_sAdd;
}
tmp = tmp + t_sAdd;
} _bstr_t strSQL = tmp;
_variant_t RecordsAffected;
try //采用sql语句形式
{
m_pConnection->Execute( strSQL, &RecordsAffected, adCmdText );
}
catch(_com_error e)
{
CString t_s = e.ErrorMessage();
AfxMessageBox((t_s));//"SearchSampleInfo: 无法上传到数据库"));
m_pConnection->Close();
return false;
}貌似实现了删除,但是为什么用记录指针操作不可以呢?求高手解答!
//CString tmp ("select * from Patient where PatLogicID = 0x");
CString tmp ("DELETE FROM Patient WHERE PatLogicID = 0x");
int i;
for ( i = 0; i < 16; ++i )
{
CString t_sAdd;
t_sAdd.Format( "%x", (BYTE)t_sPatLogicID.GetAt(i) );
if ( t_sAdd.GetLength() == 1 )
{
t_sAdd = "0" + t_sAdd;
}
tmp = tmp + t_sAdd;
} _bstr_t strSQL = tmp;
_variant_t RecordsAffected;
try //采用sql语句形式
{
m_pConnection->Execute( strSQL, &RecordsAffected, adCmdText );
}
catch(_com_error e)
{
CString t_s = e.ErrorMessage();
AfxMessageBox((t_s));//"SearchSampleInfo: 无法上传到数据库"));
m_pConnection->Close();
return false;
}貌似实现了删除,但是为什么用记录指针操作不可以呢?求高手解答!
而sql里,uuid转成字符,是不会出现0的。
找了很久,没有找到解决方法,只能把所有的代码改掉,唯一没解决的是在这种情况下,如何实现图像数据的修改...........
最后没有办法的办法,就是存成本地图像。
另外,ado对于64位access文件的操作,也有问题,以后开发,考虑换成别的了。