How to combine 2 excels into one, and include header from only first one

Posted on 2014-11-19
Medium Priority
Last Modified: 2014-12-26

How do we combine 2 excels into one, and include header from only first one.
Is there a any easy way to script it via a bat file.

Question by:chetan1981
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
LVL 70

Expert Comment

ID: 40453904
Do you really mean XLS(x), or rather CSV?
LVL 70

Expert Comment

ID: 40453910
The former requires Office Automation, and that only works with .NET(like) languages (VB, VB Script, PowerShell), The latter is feasible in a .cmd batch, unless there are special characters like ampersand, parens, percent signs, double quotes, in short - very delicate.

Author Comment

ID: 40455025
CSV should be fine too..thanks
LVL 70

Accepted Solution

Qlemo earned 2000 total points
ID: 40455133
copy /A firstFile.csv combinedFile.csv
more +1 <secondFile.csv >>combinedFile.csv

Open in new window


Author Comment

ID: 40455332

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Whether you’re a college noob or a soon-to-be pro, these tips are sure to help you in your journey to becoming a programming ninja and stand out from the crowd.
The SignAloud Glove is capable of translating American Sign Language signs into text and audio.
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question