Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Replace in one cursor for match in another
Message
De
22/09/2006 11:00:34
Jay Johengen
Altamahaw-Ossipee, Caroline du Nord, États-Unis
 
 
À
22/09/2006 10:56:13
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 8 SP1
Divers
Thread ID:
01156327
Message ID:
01156468
Vues:
19
No offense, but that won't work as I need to build the various footnotes. It's not a one-for-one.

>No offense, but way too much code for a simple job. Mike Yearwood showed you one solution, I prefer this variant
>select targettable
>set order to targettag in sourcetable
>SET RELATION TO sourceexpression into sourcetable
>REPLACE all field1 with sourcetable.field1 for !eof('sourcetable')
>
>>I ended up doing this which works fine, but I really would have like to use the UPDATE. Some day...
>>
>>
>>
>>SELECT iAccts
>>SCAN
>>	SELECT crsFundAcctDisc
>>	LOCATE FOR crsFundAcctDisc.Acct_ID == iAccts.Acct_ID
>>	DO WHILE .T.
>>		IF FOUND()
>>			REPLACE iAccts.FootNote WITH ALLTRIM(iAccts.FootNote) + '('+ ALLTRIM(STR(crsFundAcctDisc.FootNote))+')'
>>			CONTINUE
>>		ELSE
>>			EXIT
>>		ENDIF
>>	ENDDO
>>	SELECT iAccts
>>ENDSCAN
>>
>>
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform