Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Send updates using SPT to SQL Server
Message
De
07/12/1998 09:34:32
Marco Beuk
Innovero Software Solutions
The Hague, Pays-Bas
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Titre:
Send updates using SPT to SQL Server
Divers
Thread ID:
00164714
Message ID:
00164714
Vues:
73
TableUpdate() returns .T. but my remote table isn't updated, somethimes the error 'No update tables are specified' is in the AERROR().
I am new in this stuff so could please someone tell me why this code doesn't update my remote table? (VFP 5.0 & SQL Server 7.0)


SET MULTILOCKS ON
n=SQLCONNECT('Crime')

sqlsetprop(n,'DispWarnings',.T.) &&I don't get errormessages
SQLSETPROP(n,'Transactions',1)
SQLSETPROP(n,'BatchMode',.F.)
SQLSETPROP(n,'Asynchronous',.F.)

var=sqlexec(n,"select * from titles where titDescr like '%PIRATE%'","test")
var=sqlmoreresults(n)
replace titDescr with 'testestestest'
brow &&Replacement in cursor succeeded
var=cursorsetprop('Buffering',5,'test')
var=cursorsetprop('sendupdates',.t.,'test')
var=cursorsetprop('tables','titles','test')
var=cursorsetprop('keyfieldlist','titId','test')
var=cursorsetprop('updatenamelist','titDescr titDescr','test')
var=cursorsetprop('updatablefieldlist','titId, titDescr','test')
if tableupdate()
messagebox('update succeeded!!!') &&update always succeeds
endif
sqlcommit(n)
var=sqlexec(n,"select * from titles where titDescr like '%PIRATE%'","test2")
sqlmoreresults(n)
if grpnaam = 'testestestest'
messagebox('updated in remote table')&&Never seen this messagebox working
endif
brow
use in test
use in test2
sqldisconnect(n)
Répondre
Fil
Voir

Click here to load this message in the networking platform