Quantcast
Channel: UiPath Community Forum - Topics tagged error
Viewing all articles
Browse latest Browse all 4384

Contains / Not Contains clause in Query statement

$
0
0

@Gmatmut wrote:

I try to make a select from a datatable but I have errors.

First, I create a List of String and try to use Contains operator:

dtInJobData.AsEnumerable.Where(Function( r) (r(“ID”).toString<>"" And r(“Etat”).toString.Contains(listNotInSQL)).CopyToDataTable

with

variable: listNotInSQL
variable type: List < String >
and Default Value: New List(Of String)(New String(){“Terminé”,“En attente”})

but I always have the message Assign: The source contains no DataRows, and it’s not correct.

Secondly, I try to use !Contains operator:

dtInJobData.AsEnumerable.Where(Function( r) (r(“ID”).toString<>"" And !r(“Etat”).toString.Contains(listNotInSQL)).CopyToDataTable

with the same List
and I don’t understand the error message:
Leading ‘.’ or ‘!’ can only appear inside a ‘With’ statement

Thanks in advance

Posts: 3

Participants: 3

Read full topic


Viewing all articles
Browse latest Browse all 4384

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>