Cannot get the for each to validate the column data

Above this is have two read ranges and I’m trying to make sure that the data in Column-1 matches the data in Primary_NPI. I can see the data and that it matches. But I get the failed message. This should be straight forward. PINRow.item(“Column-1”).ToString = MasterPID.item(“PRIMARY_NPI”).ToString

give a try on:


if it is still failing, then go for debug and inspect the variable values:
Understanding the 6 Debugging Panels of UiPath in the easiest way possible! - News / Tutorials - UiPath Community Forum

I tried it and still the same issue. I placed an output data table and write line and I see the data from the first data table. and did this for the 2nd data table this should match.

just debug and check the variables. Also you can prototype the statements within the immediate panel

Thanks, just did that and I see in the variables the dtPIN and the values and dtPID and the values. so it looks like the data is there.

perfect, but now also the nested loops can be checked. Only when on same row Index the values are matching, then it will go into the then case (I did it)

We don’t know your details and requirements. Keep in mind, that the implemented check is not about "there is one row where somewhere else a row with same value exists.

Maybe you can share the output from immediate panel for following:

  • dt_PIN.Rows(X)(“Column1”).toString
  • dt_PID.Rows(X)(“PRIMARY_NPI”).toString

X= is an Integer and row Index where both rows has same value

Right click the If, and select Toggle Breakpoint. This creates a breakpoint so in debug mode it will pause at the If. Click Debug.

When it pauses before processing the If, you can look in the Locals panel and see the result of the next statement (the If) and dig into it.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.