Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Making a SQL Pass-through updatable.
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Divers
Thread ID:
00434375
Message ID:
00434396
Vues:
15
Hi, Ronald!

Following is the sample of properties settings I made for SQL Server:

I use following SQL:

"Select doc_id, cName, cType, tentered, tupdated, cEntBy, cUpdBy, cont_id, lPrivate, cOrigExt, convert(bit,0) lView from documents"

Than, following commands work without errors:


&& set updating properties
CURSORSETPROP('Tables', 'dbo.Documents')
CURSORSETPROP('UpdateNameList', ;
'doc_id dbo.Documents.doc_id, cname dbo.Documents.cName, ctype dbo.Documents.cType, ' + ;
'tentered dbo.Documents.tentered, tupdated dbo.Documents.tupdated, cEntBy dbo.Documents.cEntBy, cUpdBy dbo.Documents.cUpdBy, cont_id dbo.Documents.cont_id, lPrivate dbo.Documents.lPrivate, cOrigExt dbo.Documents.cOrigExt')
CURSORSETPROP('KeyFieldList','doc_id')
CURSORSETPROP('UpdatableFieldList', 'doc_id,cName,cType,tentered,tupdated,cEntBy,cUpdBy,cont_id,lPrivate,cOrigExt')
CURSORSETPROP('SendUpdates', .T.)

&& try it
CURSORSETPROP('buffering', 3)
go 2
repl cName with 'Whatever'
tableupdate(.T.,.T.)



In your case format may be different. Try to create remote view, open it and see format of these properties, that is how I discovered above ;)


>OK I am not sure I am wording this right so here is my question.
>
>My commection handle is 1 to an Oracle Table
>
>I issue the following...
>
>? SQLEXEC(1, [SELECT Vdr_No, vdr_add3 FROM VNDR WHERE Vdr_No = 9141], [MyCur])
>
>? CURSORSETPROP('SendUpdates',.T. ,'mycur')
>? CURSORSETPROP('Tables', 'KPOPS.VNDR')
>? CURSORSETPROP('UpdateNameList','vdr_add3', 'MyCur')
>? CURSORSETPROP('KeyFieldList','vdr_no', 'MyCur')
>? CURSORSETPROP('UpdatableFieldList', 'vdr_add3, vdr_add3', 'MyCur')
>
>BROW
>
>This should make "MyCur" updatable however I get the error....
>
>"No update tables are specified. Use the tables property of the cursor"
>
>KPOPS is the schema and the table in Oracle is VNDR
>
>What am I missing here?
>
>TIA Ron
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform