hey team
(From a In DT_2.AsEnumerable() Join b In DT_1.AsEnumerable() On a(“CREDIT AMT”).ToString NOT Equals b(“Amount in Doc. Curr.”).ToString and a(“DATE”).ToString NOT Equals b(“Posting Date”).ToString Select dt_Result2.Rows.Add({a(“CREDIT AMT”).ToString})).copytodatatable
This is showing error in Not equal pls help
Use Not before And or Or and at the start just after On
Using the Join Operator has some constraints on the syntax and blocks the NOT usage
We can rewrite to (when the case is to seen as a match case)
(From a In DT_2.AsEnumerable()
Let ca = a("CREDIT AMT").ToString
Let ad = a("DATE").ToString
Let chk = DT_1.AsEnumerable().Any(Function (b) Not ca.Equals(b("Amount in Doc. Curr.").ToString) And Not ad.Equals( b("Posting Date").ToString))
Where chk
Select r = dt_Result2.Rows.Add({ca})).copytodatatable