SKU auto creation

handbaked

New Member
Joined
Oct 8, 2013
Messages
3
Hi everyone

I am new to this forum but have a question I hope someone can help me with.

Firstly, I am not an advanced user on Excel :)

I have a very large CSV file that contains an inventory but I need to assign an SKU to every line in the CSV. This SKU needs to be a set of numbers but with the last 2 numbers/letters relevant to information contained on the same line in the csv (but in 2 different columns).

So as an example by example column D contains information regarding what is called a Status. This column either says 'New', 'Complete in Box', 'Boxed', 'Cart/CD Only' or 'Misc'. I would like to assign a number to each of these so that the last number in the SKU is 1, 2, 3, 4 or 5.

The CSV also includes another column called 'Condition'. This either shows as 'New', 'Very Good', 'Good' or 'Acceptable'. I would like to assign a letter to each of these so that the 2nd to last digit/letter in the SKU is either A, B, C or D.

How would I go about auto creating the SKU's based on this information?

Thanks in advance!
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
The easiest to understand what you are doing is to work with a few helper columns. You don't mention how the main number of the SKU is made up, so in the below example I have assumed it is an incremental number.


Excel 2010
ABCDEFGHIJKLMNOP
3XYZStatusABCDConditionFGSKU NrCond CodeStat CodeSKU
4abcd1abcd4abcd5Newabcd8abcd1abcd4abcd5Newabcd8abcd1133332A1133332A1
5abcd2abcd5abcd6Complete in Boxabcd9abcd2abcd5abcd6Very Goodabcd9abcd2166665B2166665B2
6abcd3abcd6abcd7Boxedabcd10abcd3abcd6abcd7Goodabcd10abcd3199998C3199998C3
7abcd4abcd7abcd8Cart/CD Onlyabcd11abcd4abcd7abcd8Acceptableabcd11abcd4233331D4233331D4
8abcd5abcd8abcd9Newabcd12abcd5abcd8abcd9Very Goodabcd12abcd5266664B1266664B1
9abcd6abcd9abcd10Complete in Boxabcd13abcd6abcd9abcd10Goodabcd13abcd6299997C2299997C2
10abcd7abcd10abcd11Boxedabcd14abcd7abcd10abcd11Newabcd14abcd7333330A3333330A3
11abcd8abcd11abcd12Cart/CD Onlyabcd15abcd8abcd11abcd12Very Goodabcd15abcd8366663B4366663B4
12abcd9abcd12abcd13Boxedabcd16abcd9abcd12abcd13Goodabcd16abcd9399996C3399996C3
13abcd10abcd13abcd14Cart/CD Onlyabcd17abcd10abcd13abcd14Acceptableabcd17abcd10433329D4433329D4
SKU
Cell Formulas
RangeFormula
M4=ROW()*33333
N4=IF(I4="New","A",IF(I4="Very Good","B",IF(I4="Good","C",IF(I4="Acceptable","D","Err"))))
O4=IF(D4="New",1,IF(D4="Complete in Box",2,IF(D4="Boxed",3,IF(D4="Cart/CD Only",4,"Err"))))
P4=M4&N4&O4
 
Upvote 0
Thanks so much for the prompt response, that has worked a treat! I can now understand how it is done and I can modify it accordingly.
 
Upvote 0
A question I hope you or someone else may be able to answer is how to also add the first 3 letters of text/data from a particular column to the SKU/further helper column?

Thanks in advance.
 
Upvote 0
use =Left(G6,3)
to get the first three letters of the text in G6
 
Upvote 0

Forum statistics

Threads
1,215,494
Messages
6,125,139
Members
449,207
Latest member
VictorSiwiide

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top