How to convert datatable values to string and perform Linq query on that?

Hi All,

I have to read data from excel and put in datatable … and perform concatenation of all rows using linq query … First two rows are integers and getting added instead of concatenation. How can I convert it into string ?

  1. First step → Reading data from excel and storing in data table
    (dt_PM0_TableData)

  1. Second step → Using linq query to concat all the values in a row and put in final row

  1. Third step → Write concated data in excel

→ Expected o/p for concatenation

999100SAKOCred.of the entrepr.Creditors of the enterprise, 3rd party securities

→ Actual o/p for concatenation

1099SAKOCred.of the entrepr.Creditors of the enterprise, 3rd party securities

→ Attached input file and xaml file

Linq.xaml (10.1 KB)

Can someone please help me in resolving this ?

I have to perform only using linq query bcoz I have huge data

@Palaniyappan @ppr @J0ska @sharathraju489

Hi @Mandava_Naresh I have updated your xaml file.Please find it below.
LinqQuery.xaml (10.6 KB)

If it works for you please mark it as solution…

Thanks and Regards.
Sreejith.

Hello @Mandava_Naresh

You can refer to the below post for a reference.

@sreejith.ss Thank you very much

@Mandava_Naresh .
Glad that it worked for you…
Thanks and Regards
Sreejith…

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.