Hello,
I was wondering if someone has an idea to help my question about one of my DQ check. Basically let me explain what i have and what i want to achieve with them.
I have; one list consisting 2 columns. Column A has unique values having 2 or 3 digits with a mixed combination of letters and numbers. Column B has names according to the column A. Here is the example:
Column A | Column B |
---|---|
abc | name1 |
abd | name1 |
abe | name1 |
abf | name2 |
xy | name3 |
1a1 | name4 |
1a2 | name4 |
1a3 | name4 |
yz | name5 |
yz1 | name6 |
As you see, there is no corelation between column A and column B. I can’t assume if the value of column A is yz and value of column B is name5 then i have name5 for yz1 of column A.
And I have a field in my data lets call it as column C. Column C has values with a mixed combination of digits and letters and with different length. Such as abc1231422ad , 1a3577afdg , yz4564sdfsfs can be example.
And I have another field which is Column D having some other values.
I want to check values of column C and find their respective column B values and bring that values.
At this point, I need a DQ check for doing following steps :
- to check first 2 or 3 digits of Column C values.
- find these 2 or 3 digits combination of C values in the list of Column A.
- bring the respective values of Column B.
- compare that value with a value of Column D.
Normally I was going to create a lookup item to find those values but it is not so easy. Here are some of challanges :
- Since my values of column D could be shorter version of column B, i need to have an approach to find not exact match but the nearest match. (like vlookup in excel)
- Some values of column A look so similar but they have some other values of column B. If I select first 2 digits of the value of Column C, it might be wrong value as there is another value of column B for a first three digits of column C.
Please let me know if you need more clarification, I hope someone has an idea to help me
Thanks !