cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
enteron
Regular Visitor

Power Query: List the words contained in a cell that occur in another query

<p>Is there a way I could get another column to display a list of items that occur in another query from a specific column?</p>
<p>&nbsp;</p>
<p>Example:</p>
<p>TextList</p>
<table>
<tbody>
<tr>
<td>This garden has an apple tree.</td>
<td>Apple</td>
</tr>
<tr>
<td>The basket has apples and bananas.</td>
<td>Apples, Bananas</td>
</tr>
<tr>
<td>The banana cake has corn.</td>
<td>Banana, Corn</td>
</tr>
<tr>
<td>The fox jumped over the dog.</td>
<td>Null</td>
</tr>
</tbody>
</table>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>Query to search the word/s from:</p>
<p>&nbsp;</p>
<p>Fruits</p>
<table>
<tbody>
<tr>
<td>apples</td>
</tr>
<tr>
<td>bananas</td>
</tr>
<tr>
<td>corn</td>
</tr>
</tbody>
</table>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>Appreciate the help!</p>
2 ACCEPTED SOLUTIONS

Hi,

 

You may refer to my solution here.

 

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

Thanks for the input Ashish! I'm wondering though if it's also possible to extract certain phrases and get a table/list output if the source cell contains a sentence and there are no delimiters.

View solution in original post

8 REPLIES 8
v-yulgu-msft
Microsoft
Microsoft

Hi @enteron,

 

Please share sample data and show us desired output to make your requirement more clear.

How to Get Your Question Answered Quickly

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Sorry about that didn't realize the tables didn't show up as intended. 

 

Phrases/Words to Match

Yellow Banana
Red Apple
Blue Berry

 

 

Text StringList/Output

Green Banana, Yellow Apple, Blue BerryBlue Berry
Red Apple, Blue Berry, Green BananaRed Apple, Blue Berry
Yellow Banana, Red Apple, Red BerryYellow Banana, Red Apple
Red Banana, Yellow Apple, Blue BerryBlue Berry

 

Thanks!

Not sure but is this possible?

Hi,

 

This is possible.  Here is the result i got.  I will share my solution in a couple of days.

 

Hope this helps.

 

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Thanks in advance!!! Hope you could share it

Hi,

 

You may refer to my solution here.

 

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

Thanks for the input Ashish! I'm wondering though if it's also possible to extract certain phrases and get a table/list output if the source cell contains a sentence and there are no delimiters.

View solution in original post

You are welcone.  If my reply helpd, please mark it as Answer.  I doublt if i can help you with your second question.  Share the data and show the expected result.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Helpful resources

Announcements
PBI User Groups

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group!

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are You Ready?

Test your skills now with the Cloud Skills Challenge.

Top Solution Authors