Column A has product SKU for a shipped unit.
Column B has waybill # for that shipped unit.
Column C has status of that shipment (Delivered, In-Transit, Delayed etc.).
Because more than one unit ships under the same waybill (it's in the same box) there are many rows with duplicate waybill #s. For example,
Product SKU | Waybill # | Status
12345 | 356498712 | In-Transit
98765 | 356498712 | In-Transit
65432 | 123456789 | Delivered
I have hundreds of products being tracked based on the waybill #s and some waybill #s are associated with 30 or more products being shipped in the same box. (Each waybill # = 1 box)
So, if I change the status of the first product in the example above from In-Transit to Delivered, how can I have Excel automatically change the other units associated with the same waybill # to also show Delivered?
I've tried Googling this but it's hard to make a search term that doesn't return all sorts of unrelated but similar results. I'm getting results that point to counting dupes, highlighting dupes etc. But nothing to instruct on what I'm looking to do.
I've made an easy example, hope you can adap it.
Your data is kind of like this:
An easy and no complex solution would be creating a second list of just Waybills and status, like the one below (I created this data in a new sheet called WAYBILLS):
Then, in the data with Sku Codes, in column STATUS I have this formula in C2:
=VLOOKUP(B2;WAYBILLS!$A$2:$B$6;2;FALSE)
And dragged down all. So now the status of each product SKU is linked to second seet WAYBILLS with this formula.
So if I Change something in sheet WAYBILLS it will autoupdate.
I've uploaded a sample to my Gdrive if you want to check it out: https://drive.google.com/open?id=1NMR_zPsjGWiKj3Qdk_0SULoe_U2-ZLQe
Hope you can adapt this to your needs.
Related
I am currently doing a sales summary consist of lots of customers, and I am trying to find a way to automatically update the value from the main sheet to individual customers sheet as there are too many customers for me to do that.
The Main Sheet would look like like this with headers
| Serial| | Date | | Customer Name| | Product Info|
| 001 | |Jan4th| | Mike | | Apple |
i am trying to create a formula so that the other individual sheet could only extract rows that was from only the customer (Mike), and other sheets would be of other customers as well.
It would help a lot if the formula can auto add in value that would soon be update as well, as other method i found only able to distribute available values, and when there are new value to be add, i have to repeat the process again which is not effiecent given the number of customers i have to summary for
If not formula then any other method would help too, but VBA is a bit above my capability so if you can provide detail for how i can make use of it, it would be delightful
If anyone can come up with anything i would be grateful, thank you for your attention
i have tried the copy paste link but they do not auto update new value after the paste.
First question on Stack, but not my first visit!
Basically I have this huge Excel database (>24 000 rows, merged from different tables) I have been working on for weeks and now that I'm done adding new entries, I have to clean it by removing a lot of duplicates.
The array/table is structured in the following manner :
+---------+-------+--------------------+-------------+--------------------+
| Company | Name | Address | Phone | Email |
+---------+-------+--------------------+-------------+-----------+--------+
| Baij&Co | Steve | 458 Preston avenue | 4156854789 | steve#baij&co.com |
I did search through conventional methods but they don't exactly answer my problem, such as:
Using the "Remove Duplicates" Excel button by selecting all columns to make sure I only keep unique values
Using the filtering method to identify the duplicates and then remove them.
However, my goal is to remove the duplicates for which the given row(s) contains the minimal amount of information, as shown in this example:
+--------- +-------+--------------------+-------------+--------------------+
| Company | Name | Address | Phone | Email |
+--------- +-------+--------------------+-------------+--------------------+
| Baij&Co | Steve | (blank) | 4156854789 | steve#baij&co.com |
| Baij&Co | Steve | (blank) | (blank) | steve#baij&co.com |
| Baij&Co | Steve | 458 Preston avenue | 4156854789 | steve#baij&co.com |
Here, I would like to remove the 1st AND 2nd row as they contain less information (missing address & phone entry) about the same contact.
Does it makes sense..?
I only know the basics of VBA (like creating a userform to add a new contact and fill out the entered information in the right cells) but I struggle with advanced algorithms.
I just know the VBA related function cannot be customized, apart from selecting the columns in which I want to remove the duplicates :
Sheets("Database").Range("ContactsTable").RemoveDuplicates Columns:=1:15, Header:=xlNo
Any ideas?
Thanks fellas!
So I followed #Tim Williams 's suggestion (which is similar to Scott's actually) and did the following:
I realized that email addresses were the unique identifier (or primary key) and I have to delete rows that don't contain any (as it becomes useless to have a contact file without contact information).
I added a column named "Count" and inserted the following formula:
=COUNTIF(N:N; N2)
--> Here, "N:N" is the column containing all email addresses. "N2" being the first cell.
I then sorted the table by descending order on the newly "Count" column to have the most occurrences first.
Then used the "Remove Duplicate" Excel tool and selected the email address column.
As a result, 10 000 rows have been removed (out of 24 000). One thing for sure is this table contains now unique contact files based on the email address. However, I will never know for sure if the most filled row was kept for each contact sadly (unless I spend days comparing both databases, row after row).
Problem solved I guess! Although I would be interested in a VBA-script to do the same (to learn on the algorithm aspect) if anyone knows anything about it :-)
Thanks again!
I have a homework assignment where I have to merge data of two excel sheets by performing some cleansing operations using formulas.
Sheet 1:
OrderID | Full Name | Customer Status
1001 Waqar Hussain Silver
2002 Ali Moin Gold
Sheet 2:
OrderID | First Name | Last Name | Customer Status
A1003 Junaid Ali 2
A2004 Kamran Hussain 1
Sheet 3:(Combined Sheet) - Expected
OrderID | Full Name | Customer Status
1001 Waqar Hussain Silver
2002 Ali Moin Gold
1003 Junaid Ali Silver
2004 Kamran Hussain Gold
There are probably a lot of ways to do this. First make sure the data is cleaned. If you are already 100% positive the data is clean you can skip this step. If you aren't sure it's better to be safe than sorry. For each column create a new column using the CLEAN and TRIM functions to remove any non-printable characters and any extra spaces. Something similar to =TRIM(CLEAN(A2)). Then drag the formula for each cell.
After this in order to merge the data together we need something to join on. The full name seems to make the most sense. On sheet two we'll write a new function to join the first name and last name together. The =CONCAT formula should work.
=CONCAT(First Name, " " ,Last Name). Make sure to note the extra space added by the quote. That way it matches the Full Name from Sheet 1. Looks like we'll also need to strip out the letter from Order ID in sheet 2. I'm going to assume that all Order IDs are 5 characters long. If this isn't true then you'll need a different solution. You can use =RIGHT(A2,4). This will grab the right 4 characters from the text string.
At this point let's create a distinct list. Copy the Full Names from Sheet1 and Paste them on to sheet 3. Copy the Full Names we created on Sheet2 and Paste VALUES onto sheet 3 below the full names from sheet 1. Then select all the rows in the column and go to the Data tab. Click "Remove Duplicates". This will now generate a distinct list of values.
We can now merge the data together using an INDEX MATCH. There are lots of great tutorials on how to use INDEX match in combination. It's a little long to explain on this thread, but this is a great thread explaining how it works. It's worth taking 10 minutes to fully understand it because it is a formula you will use thousands of times throughout your life.
https://www.deskbright.com/excel/using-index-match/
Let me know if I can clarify anything.
Best,
Brett
I have data from other software that outputs in the format shown attached. This is what it initially looks like. I have removed data from all other columns that were not relevant to this task (i.e. columns A - H, J, K, M, N and P).
All items have different ID #s. However, each item has the same categories. Each category can have between 1 and 3 values, either numerical or alphabetical.
The actual data I'm working with has close to 500 items.
I'm looking for a way to rearrange the data so it looks like this.
In response to a comment:
I want to do several things
1. Move everything over to start at A1; in a separate sheet is good
2. Rearrange data so the only columns are ID | CAT | Value 1 | Value 2 | Value 3
3. Have each CAT only listed once for each item
4. Move each Value with the same ID and CAT to be listed on one row
If any further elucidation is needed, please inform me.
Thanks to all!
Have you tried creating a PivotChart on a separate sheet and filtering out the blanks?
Or, have you considered filtering the information?
I think we might need some more clarification -- from your message, it seems like you just want to create headers and delete the blank rows/columns.
I have a table of clients and the products that they have purchased.
I'm looking for a simple way of being able to filter to view all clients who don't have a certain product.
Client | Product
------ | ------
John | A
John | B
John | C
Kate | A
Kate | B
Kate | D
Mary | A
Mary | D
With the above example I would want to look for which clients do not have Product -> C, the return I'm after is Kate and Mary.
I've tried looking at this in a few different ways but I feel I'm over complicating it. I was creating a table to return who has the product then doing a lookup from there against another table of all users to then find out who wasn't in the first list.
I tried using a pivot table to get what I was after but I'm only able to return who has the products rather than who doesn't, also filtering product C from the pivot table does not help as the Client still shows up having other products.
I'm hoping there is an easier way to do this.
Your assistance is appreciated.
Dane
COUNTIFS should to the trick here.
You have one cell where you enter the product to look for. Then you add a column to your table that checks if the client does not have that product.
=COUNTIFS([Client],[#Client],[Product],referenceToTheProductToLookFor)=0
This will count the rows where
the entry in the column "Client" is the same as the value in the column "client" in the current row ([Client] references the whole column, [#Client] only the current row's value of that column)
the entry in the column "Product" is the same as the one entered in your input cell
and checks if the resulting count is 0. If it is 0 the cell value will be TRUE, otherwise it will be FALSE.
If you want to avoid having to make two steps each time you change the product you are looking for (1. enter the product, 2. update the filter on the table) you could use the worksheet's On_Change macro to detect changes to the product code and then automatically update the filter on the table.