Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Inconsistent replace with's
Message
 
À
02/02/1999 15:00:16
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00183129
Message ID:
00183136
Vues:
19
>Have you seen one like this before? It's simple but maddening.
>
>The first line does not replace. The second one does.
> REPL sp_f17euc.COBOR1AGE with str(insapp.COBOR1AGE)
> REPL sp_f17euc.COBORR2 with insapp.COBORR2
>The only difference is the str() on the numeric field, which should not matter.
>
>I added output windows to confirm and flushed the buffer to ensure a write to disk as follows without success.
> wait wind sp_f17euc.COBOR1AGE +' / '+str(insapp.COBOR1AGE)
> REPL sp_f17euc.COBOR1AGE with str(insapp.COBOR1AGE)
> flus
> wait wind sp_f17euc.COBOR1AGE +' / '+str(insapp.COBOR1AGE)
> REPL sp_f17euc.COBORR2 with insapp.COBORR2
>
>Both files are open and some fields do update. I cannot use scatter/gather or tableupdate() as the type of fields of the same name are different. I have to use replace...with. Replace...with always works, doesn't it?
>
>This is not a case of other users locking the records or of memory problems. Any help? Thanks.

Hi Larry,

I'll bet you're actually getting blanks in that field. Use either TRANSFORM() or add ALLTRIM() to that numeric. Either:
REPL sp_f17euc.COBOR1AGE  with ALLTRIM(STR(insapp.COBOR1AGE))
REPL sp_f17euc.COBOR1AGE  WITH TRANSFORM(insapp.COBOR1AGE, "###"))
Should do the trick.

hth,
George

Ubi caritas et amor, deus ibi est
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform