Hi
I have extract the data (e.g, ID, Vendor Name) from a webpage and stored into a data table. Now I want to check the ID in SQL DB table whether ID is stored in the DB or not.
I am not sure which activity should be used and how ID will be checked in DB. Can someone please help me?
Hello @Naresh_Upadhyay ,
Create one temporary variable to store the website table information.
You can use Execute Query by downloading UiPath.Database.Activities
In the Execute Query Activity type select query to get all the data from table.
Now compare both (Data stored in temporary variable and execute query variable) the table using for each row activity.
Srini84
(Srinivas Kadamati)
October 3, 2020, 6:44am
3
@Naresh_Upadhyay
Once you stored the webpage data into datatable → DT1
Use ForEach Row activity to loop
Store your value as ID = row(“ID”).ToString
Use Execute Query activity to check the ID in sql table
Now you can use query like “SELECT * FROM TABLENAME WHERE ID = ID”
Create a output variable → DT2
Now use IF condition DT2.Rows.Count>0
Then It is present → Else Its not present
For more reference you can check Link
Hope this helps you
Thanks
Thanks for reply!! it worked.
1 Like
system
(system)
Closed
October 18, 2020, 7:43pm
5
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.