Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Automatic updates of data returned by stored procedure
Message
 
 
À
15/01/2008 06:39:25
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 2000 SP4
Network:
Windows 2000 Server
Database:
MS SQL Server
Divers
Thread ID:
01281864
Message ID:
01281866
Vues:
8
Yes, you can make SPT cursor updatable but connection has to be kept open. See mskb #Q138094 How to Create Updatable Views by Using SQL Passthrough and How to make SQL Pass-Through cursor updatable FAQ #8153.
>
>is there any chance to arrange an automatic updates of the data (cursor) returned by SP of MS SQL?
>
>Somehow like this example?:
>oSQL=CREATEOBJECT("rs_SQL","newcontrade",.f.)
>oSQL.cSQL="exec sp_OBS_AddBatchAIG 2"
>oSQL.lIdle=.f.
>oSQL.CSQLCURSOR="vOBS_ReadyAbout"
>IF oSQL.ExecuteSql() < 0
>	oSQL.ReleaseConn()
>	RELEASE oSQL
>	oSQL=.null.
>	RETURN
>ELSE
>	oSQL.ReleaseConn()
>	RELEASE oSQL
>	oSQL=.null.
>	INDEX on s_Contract_No TAG Contr
>	INDEX on s_Client_Surename TAG Clien
>
>*could next line work?
>
>	=CURSORSETPROP("KeyFieldList","instr_id,x_batch",oSQL.CSQLCURSOR)
>	=CURSORSETPROP("Tables","tbl_OBS_AIG",oSQL.CSQLCURSOR)
>      =CURSORSETPROP("UpdatableFieldList","Gen,Low,Placement",oSQL.CSQLCURSOR)
>	=CURSORSETPROP("UpdateNameList","gen tbl_OBS_AIG.OBS_AIG_GenEnable, 
Low tbl_OBS_AIG.OBS_AIG_LowerEnable, Placement tbl_OBS_AIG.OBS_AIG_Placement",oSQL.CSQLCURSOR)
>	=CURSORSETPROP("SendUpdates",.T.,oSQL.CSQLCURSOR)
>*---------
>
>ENDIF
>
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform