Create a new table with the results of a query that uses multiples criterias from 2 different tables

Luthius

Active Member
Joined
Apr 5, 2011
Messages
274
Guys

I have one table that contains a memo field (tblWithMemoField)
The second table has some keywords (tblWithKeyWords)

What I want to do is a query that can generate a table using the field fldCriteria(tblWithKeyWords) to find the records from the tblWithMemoField on field (fldMemo).
There is no relationship between the tables.


tblWithMemoField
IDRemarks
CompanyName
fldMemoThis field will be the target - Memo

<tbody>
</tbody>







tblWithKeyWords
idKeyWord
fldCriteriaMy criteria - Text field

<tbody>
</tbody>






Would be something literally like below - Of course the statement below doesn't work.

Code:
[COLOR=#008000][FONT='inherit'][B]SELECT [/B][/FONT][/COLOR][COLOR=#333333][FONT='inherit']CompanyName [/FONT][/COLOR][COLOR=#008000][B]FROM[/B][/COLOR] tblWithMemoField [COLOR=#008000][FONT='inherit'][B]WHERE[/B][/FONT][/COLOR][COLOR=#333333][FONT='inherit']((([/FONT][/COLOR][COLOR=#333333][FONT='inherit']fldMemo[/FONT][/COLOR][COLOR=#333333][FONT='inherit'])[/FONT][/COLOR][COLOR=#008000][FONT='inherit'][B]LIKE[/B][/FONT][/COLOR][COLOR=#19177C][FONT='inherit']"*"[/FONT][/COLOR][COLOR=#666666][FONT='inherit']+[/FONT][/COLOR][COLOR=#333333][FONT='inherit'][[/FONT][/COLOR][COLOR=#333333][FONT='inherit']tblWithKeyWords[/FONT][/COLOR][COLOR=#333333][FONT='inherit']][/FONT][/COLOR][COLOR=#666666][FONT='inherit']![/FONT][/COLOR][COLOR=#333333][FONT='inherit'][[/FONT][/COLOR][COLOR=#333333][FONT='inherit']fldCriteria[/FONT][/COLOR][COLOR=#333333][FONT='inherit']][/FONT][/COLOR][COLOR=#666666][FONT='inherit']+[/FONT][/COLOR][COLOR=#19177C][FONT='inherit']"*"[/FONT][/COLOR][COLOR=#333333][FONT='inherit']));[/FONT][/COLOR]
How can I do it?

Luthius
 

Some videos you may like

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.

Watch MrExcel Video

Forum statistics

Threads
1,099,677
Messages
5,470,083
Members
406,680
Latest member
Cleudson Dias de Almeida

This Week's Hot Topics

Top