Linq in uipath for filtering of numeric value

Hi all i am facing the issue win filtering of query using linq every time its coming AsInumerable () error. Even i have chaged xmal file too but the issue is not resolve

1 Like

Hi @akv,

Welcome to the community :slight_smile:

Can you share the LINQ query you are using for reference

1 Like

Hi
Welcome to UiPath community
kindly share your LINQ query if possible
are we trying to convert any datatype in that LINQ query

Cheers @akv

i will share you my screen shot

sure
Cheers @akv

Is the query solved ?
If not do mark the post as unsolved :expressionless:

1 Like

nope

may i know what is mentioned in the right side of that assign activity
kindly share that expression
Cheers @akv

dt1.AsEnumerable.Where(Function(row) row(β€œNAME”).ToString.Trim=β€œ1”).CopyToDataTable()

you were almost done
dt1.AsEnumerable.select(Function(row) row(β€œNAME”).ToString.Trim.Equals(β€œ1”)).CopyToDataTable()

Cheers @akv

1 Like

the reason is you were unable to filter it using that!!!

The LINQ used is to filter datatable and you need to provide it equal as what exactly :slight_smile:

Have a great day :slight_smile:

still confused can you write the query

1 Like

Is correct @akv

The query is used to compare and store it in a datatable

image

Also uncheck the solution marked earlier

Kindly have a view on this buddy
@akv

error is coming regarding boolean type

1 Like

@akv

Can I have a clearer picture of the intend of your query!!!

  • Are you basically trying to filer the NAME folder with the one’s having β€œ1”
  • Are you just intending to remove the 1 if it exist in the column β€œName”

Fine if we want to get all the rows of column Name whose values equals to 1
then
we can use a simple assign activity like this
dt = dt.Select("[NAME] = β€˜1’ ").CopyToDatatable()

simple isnt it
Cheers @akv

<?xml version="1.0" encoding="utf-16"?>TrueTrueTrue[xyz][dt1.AsEnumerable.select(Function(row) row(β€œNAME”).ToString.Trim.Equals(β€œ1”)).CopyToDataTable()]