Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL Server Table Update
Message
De
29/03/2013 09:10:16
 
 
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 7
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Desktop
Divers
Thread ID:
01569522
Message ID:
01569528
Vues:
50
Sergey

The PK field is a unique record ID, set by SQL Server itself, and the 10 records I'm editing all exist, it's purely a read from SQL. VFP runs a stored procedure from SQL Server, along the lines of:

begin
set nocount on;
select * from dbo.MyTable where RecordLive = 1
end

My VFP code performs this stored procedure, returns a dataset, loops through each record in the dataset, modifies data in each record, and then once all modifications have been done to each record the VFP code performs a table update. When you return to SQL you see that the modifications that you've done to record 10 are copied across to records 1-9, rather than 1-9 having their own unique updates.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform