@AshwinS2 value = string.Join(“,”,DT1.AsEnumerable().[Select](Function(s) s.Field(Of String)(“employee_id”)).ToArray)
can anyone help me on this
@AshwinS2 value = string.Join(“,”,DT1.AsEnumerable().[Select](Function(s) s.Field(Of String)(“employee_id”)).ToArray)
can anyone help me on this
Hi
i think we need some correction over the expression
string.Join(“,”,DT1.AsEnumerable().Select(Function(s) s.Field(“employee_id”).ToString).ToArray)
Cheers @Tamilarasanaccet
Try using assign newdt=Dt1.Select(“[employee_id]<>‘’”). copy Todatatable ()
Try this
Thanks
Ashwin.S
this is what is to be mentioned
string.Join(“,”,DT1.AsEnumerable().Select(Function(s) s.Field(“employee_id”).ToString).ToArray)
you were almost done
Cheers @Tamilarasanaccet
@Palaniyappan bro i am getting error by using this
string.Join(“,”,DT1.AsEnumerable().Select(Function(s) s.Field(“employee_id”).ToString).ToArray)
Fine aah sorry
typo mistake
string.Join(“,”,DT1.AsEnumerable().Select(Function(s) s(“employee_id”).ToString).ToArray)
no need to mention the field
Cheers @Tamilarasanaccet
Sometimes it helps to put the Type into the Statement:
DT1.AsEnumerable().Select(Function(s) s.Field(Of String)(“employee_id”).ToString).ToArray
Sometimes an explicit cast is required, so it can be done like:
DT1.AsEnumerable().Select(Function(s) CType(s.Field(Of Object)(“employee_id”),String)).ToArray
hi bro i am using above concated string in one variable and using tha variable in select method filter condition in assign activity
please find the below condition
DT1.Select(“[employee_id] NOT in (value)”).CopyToDataTable
but getting error as below
Assign: Cannot find column [value].
sorry for the incovinence i am new to this
no worries
it should be like this buddy
DT1.Select("[employee_id] NOT in ‘value’ ").CopyToDatatable()
OR
DT1.Select("[employee_id] <> ‘value’ ").CopyToDatatable()
Cheers @Tamilarasanaccet
Please use the Statement as given by me or @Palaniyappan
DT1.Select is something else as DT1.AsEnumerable().Select
Thats why you get the error
@Palaniyappan hi bro below is my statement
value = string.Join(“,”,DT1.AsEnumerable().Select(Function(s) s(“employee_id”).ToString).ToArray)
result = DT1.Select("[employee_id] NOT in ‘value’ ").CopyToDataTable
hmmmm…it seems like you haven’t removed the square brackets with [‘value’]
it should be like ‘value’
Cheers @Tamilarasanaccet
@Palaniyappan no bro i am not given bracket
please refer below code
result = DT1.Select("[employee_id] NOT in ‘value’ ").CopyToDataTable
fine,i wonder why so
kindly try once with this
result = DT1.Select("[employee_id] <> ‘value’ ").CopyToDataTable