SKU | Model Code | Prefix | Prefix Should Be |
MT-QSP6HmO24SR | QSP6 | MT | MT- |
AB46446BABSTD | 6446 | AB | AB4 |
AB664450BABSTD | 6445 | AB | AB6 |
Alteryx is producing the Prefix column above, but I need it to produce the Prefix column listed in Prefix Should Be above. How can I fix this? Special characters, numbers, and different lengths of text could all be before the Model Code string listed in the SKU. I need everything before the Model Code string in the SKU column to populate the Prefix column so that it matches the Prefix Should Be column.
LEFT([SKU], FINDSTRING([SKU], [Model code]) - 1)
Solved! Go to Solution.
@ShanMarie_1 use the left() function
@ShanMarie_1 your method
The SKU prefix is not always the same length. It changes but it always comes before Model Code in the SKU string. Will this method work for prefixes that are 4 or 5 characters?