help with search and update

ml2009

New member
Local time
Today, 17:24
Joined
Jul 24, 2009
Messages
3
Hi, I have searched to forums but cannot find a similar situation.

I have TableA with field called 'Description'.
It contains data like:
JAR:605MB/605MBR MOU
CD: FIL D27875/1 750TDW-02 BR
LSE:206SSG-770 SUG

Then I have TableB with all the product families in the field 'Products' like:
605MB
750TDW
206SSG

What I would like is a query that will search the Description field in TableA, and if any of the text in that desc matches a the product family that is stored in table B field Products, then the product would be added to what is now a blank product family in TableA.

Can anyone tell me how to accomplish this?
Thanks!
 
I am not real familiar with VBA(haven't done it in years, and wasn't too great then)....
 
Right. Here you go:

1. Create a SELECT query and drag both Table A and Table B in to the 'Diagram pane' (top bit).

2. In the 'Grid panes' (bottom bit) in the first column, select (or drag) the field 'Description' from Table A.
In the Criteria paste this in: Like "*" & [TableB]![Products] & "*"

3. Change the Query type to and UPDATE Query.

4. In the second column select (or drag) the field 'Products_Family' from Table A (the one you want to update).

5. In the same column in the 'Update To' grid paste this: [TableB]![Products]

6. Save the Query

7. Run it.

Et Voila!
 

Users who are viewing this thread

Back
Top Bottom