I want to match two excel file,I should match particular column, if its true i shld continue with work ,ifs its false i should send mail

HI Masters,

I want to submit my workflow by tomorrow morning,
i am very new to uipath can anyone help to to solve this problem please…

i want to match Number=NO.
Quantity=Quantity Received and once send message like its updated nor i should send mail like it is mismatched

ErpExcel.xlsx (8.4 KB)
ExtractedPDF2Excel.xlsx (7.9 KB)

please help me masters

thanks in advance
Akshay

Buddy @Akshay_14
can you come again with the conditions alone once…its easy buddy we can solve it

Cheers @Akshay_14

Hello,

please try the following logic:
Read Range of the two excel files, save output as 2 separate variables
Make For Each row1 in FirstExcelOutput activity (rows from first output), nested inside another For Each row2 in SecondExcelOutput (rows from second output)
Inside second For Each put If activity with condition based on column naming:
e.g.: row1.Column(“NO”).toString.Trim.equals(row2.Column(“Number”).toString.Trim And row1.Column(“Quantity”).toString.Trim.equals(row2.Column(“Quantity Received”).toString.Trim)

This condition will try to match two mentioned values from both excel files.
As True set further actions or some boolean, or Break activity to stop the loop. As False add part with Sending email.
If columns do not change their position in excel, you can refer to them like: row1(2).toString, where “2” refers to the index of the column in file.

Regards

1 Like

Thank you for quick reply master@Planiyappan

@palaniyappan 1) i Want to Read the excel.
2) Then match the values based on above mentioned condition
3) If condition is true i shld send only once mail like all values are matching
4) else values are not matching

1 Like

Thanks alot @Olgu maam

This is my attached workflow can its same like what you mentioned
once condition is getting true then im sending mail, later thats going to else condtion too and sending it has error .
Match.xaml (12.0 KB)

thanks
akshay

@olgu

Can u please Find attached workflow and check where iam going wrong

1 Like

here you go the xaml
its resolved buddy
comp.zip (23.6 KB)

Hope this would help you buddy @Akshay_14
Cheers

1 Like

@Palaniyappan
Sir iam not able to see your created activities :frowning:

can u explain it please

no worries buddy this was the sequence i handled

  1. read the first file like this
    image
  2. read the second file like this
    image
  3. used two for each row loop with if condition like this buddy
    row(1).ToString.Trim.Equals(row_2(0).ToString.trim) and row(4).ToString.Trim.Equals(row_2(2).ToString.Trim)
    image
  4. then in if conditon like this
    image
1 Like

@Palaniyappan sir

Your workflow is same like what i created, its give message like values are matched twice and values along with that its Values are not matchedd also printing…
i want workflow like once values are matched it shld not go to else part again.

add a break in THEN part buddy that would get out of inner for each row loop and wont iterate again
Cheers Buddy @Akshay_14

Values are same but iam not getting why its going to else part again…:frowning:
Please Give me logic like Once its true it shld not go to else part…

Its already added sir…

Buddy there is no need of writeline in else part,leave it blank buddy so that it would iterate though but we dont need that as a information…Cheers @Akshay_14

[quote=“Akshay_14, post:13, topic:118656”]
Values are same but iam not getting why its going to else part again…:frowning:
Please Give me logic like Once its true it shld not go to else part… @Palaniyappan and @olgu [/quote]
Values are same but iam not getting why its going to else part again…:frowning:
Please Give me logic like Once its true it shld not go to else part… @Palaniyappan @olgu

@Palaniyappan
My scenario is
if conditiion is true
i shld send once mail like its successful …

else
i shld send once mail like its successful …

Please help me out with Above logic Masters…

no worries
buddy @Akshay_14

  1. add a condition like this buddy in the inner foreachrow loop and remove the mail activity here in the inner for each row buddy
    image
  2. then in outside for each loop use a if condition after the inner for each loop like this buddy

    and make use of sen doutllook mail activity out here
    the logic is
    the mail will be send only after all the rows in inner foreach row loop gets over and as we have added the out_bool of boolean type at last of each iteration, based on that condition we can send mail with a if condition buddy
    this worked
    Kindly try this and let know buddy
    Cheers @Akshay_14
1 Like

did that work buddy @Akshay_14