cmd prompt merge flat file without header

May 2, 2011 at 07:43:50
Specs: Windows XP
Hi,
I have 300 flat file to merge, but the problem is that they contain header.
so when I do copy c:\Data\* C:\Data\Done\newfile.txt
It merge the file but with the header.

is there a way to remove the header in the merge.

thx a lot


See More: cmd prompt merge flat file without header

Report •

#1
May 2, 2011 at 08:04:03
Are they text files?

How many lines is the header?


=====================================
Life is too important to be taken seriously.

M2


Report •

#2
May 2, 2011 at 08:22:50
they are text file but without the extention and the header is 1 line for each file

Report •

#3
May 2, 2011 at 09:11:30
:: ==========================================
::
:: noheader.bat Mon 02-05-2011 23:08:19.58
@echo off > newfile & setLocal enableDELAYedeXpansioN

for /f "tokens=* delims= " %%f in ('dir/b/a-d') do (
for /f "skip=1 tokens=* delims= " %%a in (%%f) do (
>> newfile echo.%%a
)
)


=====================================
Life is too important to be taken seriously.

M2


Report •

Related Solutions

#4
May 2, 2011 at 10:06:10
im not able to make it work but I guess it's normal since the only cmd I know is copy hehehe.
thx anyway

Report •

Ask Question