Ascending order - CSV to Excel - Datatable




I tried reading a csv and stored it in datatable (dt1). I filtered the records from dt1 based on certain condition and created dt2. Finally I wrote the data to an excel sheet but the issue here, I see that records in excel are arranged in ascending order whereas in the original csv file, it didn’t have any order. Can you people tell me what’s the issue here? Is it expected? There are only 1100 records

Can’t share screenshots as it is confidential. Any help would be appreciated



Seems a strange behavior but we can try to debug.
What activities are you using in this workflow? Can you share the workflow? Or atleast the CSV portion of it?
What type of data is getting sorted? Text or number?


Hi @Selvasathappan,

Can you make a sample CSV with Demo data and then share with me, Need to check how you are filtering the data.


It shouldn’t sort the data table, unless you put it in your code to sort it. If I were you, I would double check there is no table manipulation that used OrderBy or the Sort method.