Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Replace
Message
From
18/02/1997 15:43:24
 
 
To
14/02/1997 13:31:21
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00020552
Message ID:
00020950
Views:
51
>>>>I have a table that is indexec on location. I want to replace the data in 2 of the fields with data from another table that is also indexed on location. Can I use the replace command for this or must I write some sort of procedure to do this. thanks for the help.
>>>
>>>Maybe I misunderstand you ... When you replace data in some tables you still use index tags of this table, so all new data will be sorted automatically while 'replacing'.
>>
>>
>>The problem I am having is that when I do the replace command, All of the records in the table get replaced with the first value in the other table. When what I need to do is match the locations and when they match replace one field for the matching location. i am not sure if this is any clearer.
>
>I see you could use old UPDATE command:
>SELECT table1
>UPDATE on location From table2 Replace field1 with table2.field1, ;
>field2 with table2.field2


That update command is not in the manuel, and it is burried in the on line help. I also needed to use the random tag on the end. Thanks for the help.
Bob Sides
SDGS
Vermillion, SD
Previous
Reply
Map
View

Click here to load this message in the networking platform