cmd - Removing N rows of multiple CSV and then Merging them -


i have folder multiple (dozens) csv files, , need merge them in bigger csv, removing first n rows of each individual file, , wanted in bulk operation.

i've seen here solutions "more" command, use have run once each small csv, , that's want avoid - have process daily.

to merge csvs, can use (all csvs in same folder):

copy *.csv alldata.csv

is there similar approach, wildcards or that, remove first n rows of csvs?

btw i'm running windows, can install programs if necessary.

this super easy in autohotkey.

assuming want skip first 7 rows, script this: (untested...)

n = 7  loop, *.csv {        tooltip, reading %a_loopfilename%     loop, read, %a_loopfilename%     {          if (a_index<=n)           continue         fileappend, %a_loopreadline%`n, alldata.csv     } }     tooltip, msgbox, done 

Comments

Popular posts from this blog

plot - Remove Objects from Legend When You Have Also Used Fit, Matlab -

java - Why does my date parsing return a weird date? -

Need help in packaging app using TideSDK on Windows -