How can I merge over 1,500 tsv files?

They all have the same format - column names in row 1.

Obviously I can’t do it manually, and I’m sure someone has had this issue before.

I’m new to Calc, having moved from Office a few months ago. Where should I begin?

Operating system: Windows 10. Merging these to import into a database. Around 400,000 lines total, various within each file from 1 to over 1,000.

What operating system are you on? How many lines are in each of the files? (there a limit to the number of rows in calc.
A database may be a better solution for your project. We need details to answers this! Idle prying minds wanna know! :wink:

Thank you - I updated the question.


Sort of a guess here that each file has the same columns - names and number of.

One item is to combine csv files. Tested in Linux without a problem using:

head -n 1 file1.csv > combined.out && tail -n+2 -q *.csv >> combined.out

This was found on this post → Merging contents of multiple .csv files into single .csv file. See comment under answer by zsha.

For Windows 10 here is a post → How to Merge Multiple CSV Files Using Command Prompt. Have not tested this.

Now determine where you want the data. If it is to go to a database, you need to choose which database to use. Importing this amount of data is critical in the amount of time needed depending upon this choice. For an example using 81K+ records, see this post → How to import a big amount of data into LibreOffice Base.

So depending upon the choice of residence of the data, you may want to have multiple files so 400K+ records is not a very, very, very long import task.

It was as easy as copy *.tsv complete.tsv in Windows 10.

I was in help desk for 25 years. Never knew you could do that! Thank you.