Emile du Toit
New Member
- Joined
- Mar 7, 2015
- Messages
- 22
Old but thorough product data
[TABLE="width: 500"]
<tbody>[TR]
[TD]OLD[/TD]
[TD]SKU[/TD]
[TD]Title[/TD]
[TD]Description[/TD]
[/TR]
[TR]
[TD]Product [/TD]
[TD]XXX[/TD]
[TD]Mr X[/TD]
[TD]X description detailed[/TD]
[/TR]
[TR]
[TD]Product [/TD]
[TD]YYY[/TD]
[TD]Mr Y[/TD]
[TD]Y Description detailed[/TD]
[/TR]
[TR]
[TD]Product [/TD]
[TD]ZZZ[/TD]
[TD]Mr Z[/TD]
[TD]Z description detailed[/TD]
[/TR]
</tbody>[/TABLE]
New but sparse product data
[TABLE="width: 500"]
<tbody>[TR]
[TD]NEW[/TD]
[TD]Description[/TD]
[TD]Weight[/TD]
[TD]SKU[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD]A description simple[/TD]
[TD]20[/TD]
[TD]AAA[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD]Z description simple[/TD]
[TD]15[/TD]
[TD]ZZZ[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD]B description simple[/TD]
[TD]10[/TD]
[TD]BBB[/TD]
[/TR]
</tbody>[/TABLE]
Combining best new and old data
[TABLE="width: 500"]
<tbody>[TR]
[TD]COMBINED[/TD]
[TD]SKU[/TD]
[TD]Title[/TD]
[TD]Description[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD][/TD]
[TD][/TD]
[TD]A description simple[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD][/TD]
[TD][/TD]
[TD]Z description detailed[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD][/TD]
[TD][/TD]
[TD]B description simple[/TD]
[/TR]
</tbody>[/TABLE]
I am trying to combine data from a detailed old product spreadsheet with much sparser data that is available for new products. Where the old data is available (here we are just going to look at the Description column) I want to add this data into the cell. Where a product is new though - and so it is not already detailed on my old spreadsheet - I want to add the new spreadsheet Description (as this is all there is). As you can see although the OLD and COMBINED spreadsheets have the same column order, the NEW one does not.
So in the third spreadsheet I am working in the Description column to populate the descriptions. In the first cell (intersection of the first product row and Description column) I am comparing the first SKU (product identifier) of the NEW spreadsheet with the entire SKU column of the OLD spreadsheet, to see if the SKU already exists in the OLD spreadsheet. If it does match then I want the cell to include the OLD spreadsheet Description data from the product with the SKU that matches the NEW product. If the NEW spreadsheet SKU does not match the OLD spreadsheet SKU (ie it is a genuinely new product) then I want to populate the cell with the NEW spreadsheet Description data. You can see I have added in the correct data for the COMBINED spreadsheet Description column.
The formula I tried (to populate D2) was:
=IF(ISNUMBER(SEARCH('NEW'!$D2,'OLD'!$B$2:$B$4)),INDEX('OLD'!$D$2:$D$4,MATCH('NEW'!$D2,'OLD'!$B$2:$B$4,0)),'NEW'!B2)
However, there must be an error as it returns the NEW descriptions whether or not the SKU's match.
Please help!!
[TABLE="width: 500"]
<tbody>[TR]
[TD]OLD[/TD]
[TD]SKU[/TD]
[TD]Title[/TD]
[TD]Description[/TD]
[/TR]
[TR]
[TD]Product [/TD]
[TD]XXX[/TD]
[TD]Mr X[/TD]
[TD]X description detailed[/TD]
[/TR]
[TR]
[TD]Product [/TD]
[TD]YYY[/TD]
[TD]Mr Y[/TD]
[TD]Y Description detailed[/TD]
[/TR]
[TR]
[TD]Product [/TD]
[TD]ZZZ[/TD]
[TD]Mr Z[/TD]
[TD]Z description detailed[/TD]
[/TR]
</tbody>[/TABLE]
New but sparse product data
[TABLE="width: 500"]
<tbody>[TR]
[TD]NEW[/TD]
[TD]Description[/TD]
[TD]Weight[/TD]
[TD]SKU[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD]A description simple[/TD]
[TD]20[/TD]
[TD]AAA[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD]Z description simple[/TD]
[TD]15[/TD]
[TD]ZZZ[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD]B description simple[/TD]
[TD]10[/TD]
[TD]BBB[/TD]
[/TR]
</tbody>[/TABLE]
Combining best new and old data
[TABLE="width: 500"]
<tbody>[TR]
[TD]COMBINED[/TD]
[TD]SKU[/TD]
[TD]Title[/TD]
[TD]Description[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD][/TD]
[TD][/TD]
[TD]A description simple[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD][/TD]
[TD][/TD]
[TD]Z description detailed[/TD]
[/TR]
[TR]
[TD]Product[/TD]
[TD][/TD]
[TD][/TD]
[TD]B description simple[/TD]
[/TR]
</tbody>[/TABLE]
I am trying to combine data from a detailed old product spreadsheet with much sparser data that is available for new products. Where the old data is available (here we are just going to look at the Description column) I want to add this data into the cell. Where a product is new though - and so it is not already detailed on my old spreadsheet - I want to add the new spreadsheet Description (as this is all there is). As you can see although the OLD and COMBINED spreadsheets have the same column order, the NEW one does not.
So in the third spreadsheet I am working in the Description column to populate the descriptions. In the first cell (intersection of the first product row and Description column) I am comparing the first SKU (product identifier) of the NEW spreadsheet with the entire SKU column of the OLD spreadsheet, to see if the SKU already exists in the OLD spreadsheet. If it does match then I want the cell to include the OLD spreadsheet Description data from the product with the SKU that matches the NEW product. If the NEW spreadsheet SKU does not match the OLD spreadsheet SKU (ie it is a genuinely new product) then I want to populate the cell with the NEW spreadsheet Description data. You can see I have added in the correct data for the COMBINED spreadsheet Description column.
The formula I tried (to populate D2) was:
=IF(ISNUMBER(SEARCH('NEW'!$D2,'OLD'!$B$2:$B$4)),INDEX('OLD'!$D$2:$D$4,MATCH('NEW'!$D2,'OLD'!$B$2:$B$4,0)),'NEW'!B2)
However, there must be an error as it returns the NEW descriptions whether or not the SKU's match.
Please help!!