[Linux] How to combine different csv files using command prompt in Linux operating system

| | 1 min read

Suppose you are working in a software enterprise and you have to combine different csv files to create a report. It is a tedious job if you try to combine it manually by copying and pasting. We can do it if there exists only 2 0r 3 files. But if we have to merge too many files, it is not time worthy. Here I am going to explain a simple step procedure to combine multiple csv files in linux operating system through command prompt.

Please check the below steps to combine different csv files using command prompt in Linux operating system:

First you have to gather all the csv files into a single folder.
Open that folder. For example if you have all the csv files in 'CSV' folder which is in Desktop,then type the following on the terminal

cd Desktop/CSV

cat issues*.csv > newissues.csv

where issues*.csv are the csv files which you have to combine and newissuess.csv is the result of the combined csv files.

image1_0.jpg

You can also combine multiple csv files by specifying each csv file name.

For eg: cat issues1.csv issues2.csv > newissuesnew.csv

Hope this article helps you to combine multiple csv files. The only drawback I found here was that the headers are being repeated.