+ Reply to Thread
Results 1 to 7 of 7

Extract Data based on conditions on multiple columns

  1. #1
    Registered User
    Join Date
    07-01-2013
    Location
    Indian
    MS-Off Ver
    Excel 2003,2007 and 2010
    Posts
    4

    Question Extract Data based on conditions on multiple columns

    Hi,

    I have attached sample report in which i need to extract the data to sheet2 based on a particular preference.

    Extract the complete row information of the table if item is A with latest date or B with the latest date or C with latest date or D with latest date or E with latest date.

    Your help is highly appreciated
    Attached Files Attached Files

  2. #2
    Valued Forum Contributor Harribone's Avatar
    Join Date
    02-24-2013
    Location
    Midlands, UK
    MS-Off Ver
    Excel 2019/365
    Posts
    570

    Re: Extract Data based on conditions on multiple columns

    Do you just want to show the one row of data for the latest date or do you want to show details for each item on it's latest date?
    Can you upload another copy of the workbook but on Sheet2 type out manually what should be displayed please so I/others can help you get the right solution for your needs.
    Say thanks, click *

  3. #3
    Registered User
    Join Date
    07-01-2013
    Location
    Indian
    MS-Off Ver
    Excel 2003,2007 and 2010
    Posts
    4

    Re: Extract Data based on conditions on multiple columns

    Hi,

    Corrected the master report and also provided the required report in the sheet2. For each product code i need this check to be done with priority from A to E on the latest date information and accordingly the data should go to sheet2. Hope this explanation helps you. If you need further inputs please do let me know.

    Thanks in advance
    Attached Files Attached Files

  4. #4
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Extract Data based on conditions on multiple columns

    See this workbook.
    The formulae are CSE arrays and must be confirmed with Ctrl+Shift+Enter before dragging down.

    Your data layout could be changed to make dragging the formulae across possible.
    Attached Files Attached Files
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  5. #5
    Registered User
    Join Date
    07-01-2013
    Location
    Indian
    MS-Off Ver
    Excel 2003,2007 and 2010
    Posts
    4

    Re: Extract Data based on conditions on multiple columns

    Hi Marcol,

    Thank you for the help!

    But there is a small change, the item name should also be picked up by the formula. In the sheet2 I will have only the product codes remaining things should be picked up by the formula following the preferential order.

    Also is it possible to get this solution in both ways using formulae and macro coding as well. Because my team is not so go at formulae, if it is through a custom function it will be of great help..

    Looking forward for your response..

    Thanks

  6. #6
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Extract Data based on conditions on multiple columns

    Quote Originally Posted by checkoncomp View Post
    But there is a small change, the item name should also be picked up by the formula. .....
    Is this what you mean by that?
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    07-01-2013
    Location
    Indian
    MS-Off Ver
    Excel 2003,2007 and 2010
    Posts
    4

    Re: Extract Data based on conditions on multiple columns

    Hi Marcol,

    I am sorry let me put it in writing the way I want it. Take the product code for example 1 this code might have come with many items A to Z with its respective dates and quantity. What I really want is, for the product code 1 it has to first search whether it has the item A if not B if not C it goes until Z. Preference of search is from A to Z. Then once it finds item let's say it has found A then we do not require the remaining data pertaining to code 1. Now it has to look at the dates of the item A pertaining to code 1, check which is the latest date for that item and for that particular code. Because for the same product code item A could have been coming twice with different dates, out of these i have to pick the latest one. Like I have to do it for the remaining codes until 5.

    Hope this helps you..

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1