开发者

Updating Visual FoxPro from SQL Server

开发者 https://www.devze.com 2022-12-27 19:22 出处:网络
I\'m trying to update some simple Visual FoxPro tables with SQL Server. I\'ve created a linked server with the following:

I'm trying to update some simple Visual FoxPro tables with SQL Server. I've created a linked server with the following:

sp_addlinkedserver @server = 'UTIL',
@srvproduct = 'VFP',
@provider = 'VFPOLEDB',
@datasrc = 'L:\M2MDATA\Util\util.dbc'
GO

And the following works:

select * from UTIL...utcomp

However, I cannot use the following statement:

update util...utcomp
set fmaddress = '123 Elvis Dr.'
where fcsqldb = 'M2MDATA01'

I receive the error:

OLE DB provider "VFPOLEDB" for linked server "util" returned message Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.". Msg 7333, Level 16, State 2, Line 2 Cannot fetch a row using a bookmark from OLE DB provider "VFPOLEDB" for linked server "util".

I have the latest version (开发者_如何学Python9.0) installed so I should have the latest provider. Am I doing something wrong? Is it not possible to update VFP from SQL?


There are some examples on the Fox Wiki that might help. Specifically the last one which shows how to access VFP data through OLEDB without using a linked server.

0

精彩评论

暂无评论...
验证码 换一张
取 消