Skip to main content
Solved

Comparing two fields based on a string match

  • July 31, 2016
  • 1 reply
  • 274 views

Forum|alt.badge.img

Hello All, I have two tables like below. I want to know the difference (add, delete, unchanged) of the TractID field between these two tables. For instance, i want to have a output showing

unchanged: 1001, 1003

added: 1002, 1004, 1005

deleted: 1009

I didn't see the ChangeDetector transformer is able to compare two fields based on a string match. How to achieve this? I appreciate your help!

Table 1 (old):

IDTractID101001111003121009

Table 2 (new):

UniqueIDTractID1100121002,1003,100431005,1006

Best answer by takashi

Hi @fmenewbie, the ChangeDetector can compare entire string match, but cannot detect partial matching. Split TractID of the table 2 into individual id values using the AttributeSplitter and explode the records on the resulting list using the ListExploder. You can then compare individual TractID using the ChangeDetector.

View original
Did this help you find an answer to your question?

1 reply

takashi
Influencer
  • Best Answer
  • July 31, 2016

Hi @fmenewbie, the ChangeDetector can compare entire string match, but cannot detect partial matching. Split TractID of the table 2 into individual id values using the AttributeSplitter and explode the records on the resulting list using the ListExploder. You can then compare individual TractID using the ChangeDetector.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings