Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-02-2023, 10:56 AM
zevbn zevbn is offline extract data from table based on data from another table Windows 10 extract data from table based on data from another table Office 2021
Novice
extract data from table based on data from another table
 
Join Date: Dec 2023
Posts: 3
zevbn is on a distinguished road
Default extract data from table based on data from another table

I have table A, which contains thousands of rows. This table has an ID to every row.



Only part of the rows in Table A interests me. Thus, I have created a second table, B, which contains only one column, ID. Table B is the criteria for extracting the relevant rows from Table A.

I want to create table C, which will contain only the relevant rows from A.

Another issue: data in Table A changes frequently.

How do I do that in Excel? Preferably automatically.

Thanks

Last edited by zevbn; 12-02-2023 at 11:14 PM.
Reply With Quote
  #2  
Old 12-02-2023, 11:19 PM
ArviLaanemets ArviLaanemets is offline extract data from table based on data from another table Windows 8 extract data from table based on data from another table Office 2016
Expert
 
Join Date: May 2017
Posts: 858
ArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud of
Default

Why bother with separate tables?

Simply add a column to your table (e.g. with header InList), which displays some info about index for this row being registered in second table (TRUE or False, or "Listed", or whatever) using VLOOKUP(). Then set the filter on for your 1st table. Now you can set the filter for your table for only rows listed in second table to be displayed whenever you need this - simply by clicking on filter triangle on InList header, and setting the filter condition (e.g. to TRUE or False or Display All).
Reply With Quote
  #3  
Old 12-03-2023, 04:45 AM
p45cal's Avatar
p45cal p45cal is offline extract data from table based on data from another table Windows 10 extract data from table based on data from another table Office 2021
Expert
 
Join Date: Apr 2014
Posts: 855
p45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant future
Default

Quote:
Originally Posted by zevbn View Post
Preferably automatically.
What version of Excel?
Best attach a workbook with this setup.
Reply With Quote
  #4  
Old 12-03-2023, 07:56 AM
zevbn zevbn is offline extract data from table based on data from another table Windows 10 extract data from table based on data from another table Office 2021
Novice
extract data from table based on data from another table
 
Join Date: Dec 2023
Posts: 3
zevbn is on a distinguished road
Default

Windows 10, Office 2021
Reply With Quote
  #5  
Old 12-03-2023, 08:03 AM
p45cal's Avatar
p45cal p45cal is offline extract data from table based on data from another table Windows 10 extract data from table based on data from another table Office 2021
Expert
 
Join Date: Apr 2014
Posts: 855
p45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant futurep45cal has a brilliant future
Default

In the absence of a workbook:
Code:
=FILTER(TableA,ISNUMBER(MATCH(TableA[ID],TableB[ID],0)),"None found")
Reply With Quote
  #6  
Old 12-04-2023, 01:04 AM
ArviLaanemets ArviLaanemets is offline extract data from table based on data from another table Windows 8 extract data from table based on data from another table Office 2016
Expert
 
Join Date: May 2017
Posts: 858
ArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud ofArviLaanemets has much to be proud of
Default

Attached is an example of solution I described in my previous post.

In Table on sheet Data are 11 rows of data with different ID values.
In Table on sheet IdList are entered ID's you want to follow.
For Table on sheet Data is set a filter for column InList = TRUE, so only rows you want to follow are displayed.

In case you add new records to filtered Table on sheet Data, you have to refresh the filer to get the table filtered properly (obviously new ID's are missing from IdList Table, so you must get those entries to be hidden - or add them to IdList Table too).

With Table I mean Defined Table.
Attached Files
File Type: xlsx TableFiltering.xlsx (12.3 KB, 3 views)
Reply With Quote
  #7  
Old 12-04-2023, 05:36 AM
zevbn zevbn is offline extract data from table based on data from another table Windows 10 extract data from table based on data from another table Office 2021
Novice
extract data from table based on data from another table
 
Join Date: Dec 2023
Posts: 3
zevbn is on a distinguished road
Default

Thanks a lot
Reply With Quote
  #8  
Old 12-10-2023, 12:46 AM
Pecoflyer's Avatar
Pecoflyer Pecoflyer is offline extract data from table based on data from another table Windows 10 extract data from table based on data from another table Office 2021
Expert
 
Join Date: Nov 2011
Location: Brussels Belgium
Posts: 2,748
Pecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant future
Default

Please mark thread as solved ( under "thread tools"). Thx
__________________
Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post
Reply With Quote
Reply

Tags
extract criteria

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
extract data from word table thiennguyen93 Word VBA 1 07-27-2022 07:16 AM
Extract data from multiple table a4avinash Excel 4 02-28-2022 08:30 AM
extract data from table based on data from another table Automatically extract data from a table into another word document OfficeAssociate99 Word VBA 1 05-28-2017 11:19 PM
extract specific pivot table data to a new sheet theexpat Excel Programming 0 02-18-2016 10:08 AM
extract data from table based on data from another table How to Extract Data from table based on pattern. PRA007 Word Tables 4 03-17-2015 11:05 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 08:15 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft