How to find match

Hello friends…

I am extracted addres from website by extractdata in Output : DTvalue …now wanted check match it with data in variable like Inputcity ,Inputzip, Inputstate…etc. .how to do that if i dont wanted to use for each row data table activity.

Thanks,

@Bot_Learner

dt.AsEnumerable.any(Function(a) a("ColumnName").ToString.trim.Equals(inputstr))

gives you boolean output and inputstr is your variable

can you please provide more information about your requirement

1 Like

@Shiva_Nikhil

I have extracted address as output: Datatable Variable e.g. Dtaddress

And i have adress in variable e.g. InputCity, InputState, InputZip…wanted to check address in Dtaddress and input variables are matching or not…if i use if activity

If > Trim(Dtaddress.ToLower).Contains(InputCity)

Error : ToLower is not a member of System.Data.dataTable

@Bot_Learner

if you want to check only specified column then use this

dt.AsEnumerable.any(Function(a) a("ColumnName").ToString.trim.tolower.contains(InputCity))

in place of columnname you can pass the columnname which you want to check

1 Like

Hi @Bot_Learner

Use

Dtaddress.AsEnumerable.Any(Function(x) x("ColumnWhereValueIsFound").ToString.Trim.ToLower.Contains(InputCity.Trim.ToLower))
1 Like