PDA

View Full Version : Replace data of a query with data of another table



cherosoullis
11-30-2006, 12:43 AM
I have imported one table witch is split using queries. Later I have created another table with values witch represents values of queries wich needs to be replace with values of table. The attached file is reference. I dont know how to make the queries retrieve the values of the second table and update with them. Lets say that in a query a field with value "3333" wich meand "Giannis" as reference with the first table. I want the value to be change automatically but I dont know how to do this.
Maybe relationships will to the trick.
Can you please help me on this issue?

OBP
11-30-2006, 05:40 AM
Hello cherosoullis, I am not quite sure what you want to do.
I assume that you want to replace the data in the Import Table with the data in the Replace Ones Table only if the number Values match, which yours do not.
Even if they did your data structure in the 2 tables will not allow you to replace "333398798" with "Giannis" because the Import table field is numeric and the replacement table field "Description" is Text.
What I have done is to add a Text field to the Import Table called "replacement data" and mde 2 of the records in the replacement table match those in the import table.
I have used that matching data in an "Update" query to add the names to the "replacement data" fields of the 2 matching records.
There is a copy of the original Import table to show how it looked before the update query is run.
I hope this is what you wanted it to do.

cherosoullis
12-01-2006, 12:13 AM
thanks it help me