Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Copy the contents of 1 field to another field using 2 ta
Message
De
16/02/2004 04:50:30
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00877557
Message ID:
00877573
Vues:
13
>I am trying to replace a field named modacad.path in a table called modacad with a field named paths.path in a table called paths where the mainkey (field) is the same in both tables. Here is my syntax:
>
>
>SET DEFAULT TO 'C:\Pathproblem'
>select paths
>go top
>scan
>  if seek(mainkey,'modacad')
>     replace modacad.paths with paths.path
>  endif
>endscan
>
>
>I cannot get this to work. Can anybody help me please?
>
>MAny Thanks

Neil,
You could use Update-SQL :
SET DEFAULT TO 'C:\Pathproblem'
select paths
local luMainKey
scan
  luMainKey = paths.MainKey
  update paths set path = paths.path ;
     where mainkey = m.luMainkey
endscan
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform