I have a question that I a may not be thinking correctly about. But I have an a long excel file that I pull from somewhere else with the following columns:
Project_Name1, Employee_Name1, Date_Worked1, Hours_Worked1
In another sheet I have these columns
Project_Name2, Employee_Name2, Begin_Date2, End_Date2, Hours_Worked2
This second sheet is filled with data, and works just fine.
However, it turns out that I have some employee names that I do not know that are also working on the same project. I need to figure out the names of the employees and then sum the number of hours they worked for a given period.
So I need a lookup with three criteria:
Project_Name1 = Project_Name2
Employee_Name1 <> {Array of Employee_Name2}
Begin_Date2 <= Date_Worked1 > End_Date2
Returning Employee name.
Once I have the employee name, I can do a sumifs=() and get the total hours they worked no problem.
I have tried a number of combinations of Index Match functions, using ctrl-shift-enter... and have not been able to figure out it. Any help would be greatly appreciated.
What you're talking about doing is extremely complicated and a little bit past what Excel was designed to do by default. However, there are a few workarounds that you can use to attempt to get the information that you're looking for.
It's possible to do multiple-criteria VLOOKUPs and SUMIFs by concatenating fields to make a multi-part identifier (Ex: Insert a new column and have a forumla in it like =A1&B1)
Open a new workbook and use Microsoft Query (I'm not sure if you can select from more than one sheet, but if you can select from multiple sheets like tables you should be able to write a semi-complex query to pull the dataset you want.
http://office.microsoft.com/en-us/excel-help/use-microsoft-query-to-retrieve-external-data-HA010099664.aspx
Use the embedded macro feature and use visual basic script to write out your business logic. (Hotkey is ALT+F11)
One way to do this would be to first create an additional column to the right of entries on the sheet you're trying to pull employee_name from: =ROW()
You could then use an array formula like you were trying to implement to pull the corresponding 'match' row:
{=SUM((project_name1=projectname2)*(employeename1<>employeename2)*(begindate<=date_worked1)*(date_worked1>end_date2)*(match_column))}
You could then use this returned match_column entry within the index as you described to retrieve the appropriate entries.
Related
Currently the stock process at my company is very manual and it normally doesn't get carried out due to the process being rather boring. Currently all excel based I am slowly moving over to SQL that will automatically update the information.
We have come up with a naming system/code for each item, this is made up from several fields on the excel document. However there is the same codes in different columns that we wish to remove for when we push into SQL (Basically we just want the 1 line item and a count of how many times it has been used)
It has to be dynamic. (I can add an extra tab to the excel document to do any magic required) and if possible not use any Macros
So the data starts like this:
#Counts and then the duplicates are removed to produce this list
I have tried a range of countifs/Vlookups and I can get it roughly working but its not dynamic enough and I end up having multiple rows of 0 Qtys
Hopefully this is enough information
Cheers all
It looks like a very similar question was answered here.
After plugging in that formula in a different column, you can use the CountIf function in the next column.
I have been searching high and low for a way to solve my dilemma, in different ways, so I am trying to post both of the things I've been trying to do:
The challenge version 1:
I want to extract the entire row with information tied to the name which is the latest entry of that name in the table. So from the table below I would want to collect the entire row which contains the information: "A, Jack Black, 01.01.2029, 10:20". I simply want to copy the entire row to another sheet. But one important factor is that it has to happen automatically.
So i need functions which can check if: Is there another entry with the same name, higher up in the table? If so, DO NOT COPY THE ROW. If there ain't another entry with the exact same name higher up in the table, COPY THE ENTIRE ROW, to another table, within another sheet.
The challenge version 2:
What I really want to do is count the number of unique people(unique names) per. department, and summarize this in another table. Basically this means that "Jack Black" should be counted as 1 person, in department A.
So the result I want, is a table looking like this (the one beneath), where the number of people does not contain any duplicate people (names). OR it does not function with a dynamic table, which updates the information it contains on the fly. I can make this happen if I am copying from a static table, but as stated above, the table is dynamic and updates with new information every minute...
So far i've tried excel's built in filtering, but this does not work automatically. I've also tried using functions like in this guide: https://excel-bytes.com/how-to-extract-a-dynamic-list-from-a-data-range-based-on-a-criteria-without-filters-in-excel/. However every solution i find seems to need criteria for filtering out duplicates or does not function when copying information from a dynamic table.
Does anyone know how to reach my desired result, without implementing criteria for selecting the rows or counting rows as stated above? VBA code is not an option at the moment :(
In advance, THANK YOU, I've really tried solving this, but I feel like this just might break my head wide open soon if I can't solve it. HEEEEELP!
Sincerely
haakonlu
Hoping you can help me out.
I have a total of three tables here. I've been trying to figure out a formula that will give me the header (the names) of the two criteria specified in H1 and H2. I was able to get the result I want, but for the first table only (Hailey).
The problem is to find out who among the three teachers handled the "subject" within the specified month as well.
Also, I couldn't figure out how to get all the results if ever there are two names that match the criteria. Thank you in advance for your help.
as Jeeped said above this is essentially bad database/table methodology but it is not hard to fix, what you need to do is create three columns one for the name, subject and month.
Then what you can do is just run a simple SQL/Google Query to find out who is doing what.
I've created a template based of your screenshot above but with three columns, have a play around and if you redesign your spreadsheet just let us know and we can help you to design a query for your issue.
use the drop downs to get your desired query, if you select name & month you get that range, if you select a month you get all names for that month.
https://docs.google.com/spreadsheets/d/1yERKtQocnVqopqh6CCn6Rdj143bYyr_IjSDnzCLSm_8/edit?usp=sharing
This is my 1st post here (and not allowed to paste images). I have been trying to solve this issue for a couple of days with no luck. I'm working on an Excel spreadsheet for a game and cannot return a name based on multiple criteria. See below:
Table
I am trying to return, for example, the name of the Guardian with the highest amount of games played.
I've tried Index/match/sumproduct combinations but I can't figure this one out. Can you help me?
=index(Data!$A:$H,match((1,Data!B:B=Overview!B12)*(Data!C:C=Overview!B23)),0),1)
=MAX(IF(Data!B:B=Overview!B12,Data!C:C))
I'm thinking if I could join these two formulas together I might be able to make it work.
Try this array formula:
=INDEX(Data!$A1:$A99,MATCH(MAX(Data!$C$1:$C$99*(Data!$B$1:$B$99=B12)),
Data!$C$1:$C$99*(Data!$B$1:$B$99=B12),0))
CtrlShiftEnter
Notice that we should avoid using "full columns" in array formulas because they would introduce the computation of huge arrays and hence would slow down the formulas. I limit it here to 99 rows, use a limit that is big enough to span your data.
I'm trying for the life of me to figure out Excel VBA but I've been getting nowhere.
Here's what I'm needing to do:
Have a list of thousands of entries - each one corresponding to a ticket for a customer. Columns include information like client name (Column B), # of minutes worked on per ticket (Column I), etc.
We're trying to make a macro that totals the # minutes of worked on for all tickets of a specific client in a new row directly below, then hide all of those rows.
The end result should be only seeing a row containing "Total -client name here-" in the name column, then the total number of minutes in the # of minutes column.
The previous macros I've done aren't dynamic and were done via recordings within excel (which obviously don't work the way I wanted to, apparently).
Programming isn't my forte, and all this has been doing is making me want to pull my hair out. Any help?
It sounds like you'd be better off using a database like Access. You can enter all your information into a table and then write a query to find what you need. If you don't want to use Access, we'll need a better idea of what you're trying to do.