How to combine different Excel sheets into a single work book using UNIX


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting How to combine different Excel sheets into a single work book using UNIX
# 1  
Old 08-27-2008
How to combine different Excel sheets into a single work book using UNIX

Hi All,

I have 4 excel files and i want to combine these 4 files into a single workbook .. my constraints is each work sheet should go to a seperate sheet or tab with sheet name ..

my final workbook should have 4 tabs(sheets) each for one.

Thanks in Advance..
# 2  
Old 08-27-2008
useing the xml format (which is an acceptable XLS file, I have in oracle, created a spreadsheet with as many as 10 different workbooks.

Not having the Excel file in excel's XML format, I don't think I would even try.

Basically, and you can see the information easily in XML, there is a separate WORKBOOK tag for each. Cut and paste would do it.

By if they are XLS native, send to a PC and combine there.


Quote:
Originally Posted by jagadish99
Hi All,

I have 4 excel files and i want to combine these 4 files into a single workbook .. my constraints is each work sheet should go to a seperate sheet or tab with sheet name ..

my final workbook should have 4 tabs(sheets) each for one.

Thanks in Advance..
# 3  
Old 08-27-2008
The easiest way would be to save the input files as XML Spreadsheet format instead of XLS. Then create a new XML File as follows:
1. Remove the tags <Workbook> </Workbook> from all the input files.
2. After step - 1, Extract all the remaining contents of the input files and paste it between the tags <Workbook> </Workbook> in the new XML file.
The final XML file when opened in excel will show multiple worksheets as expected.
# 4  
Old 08-27-2008
maybe?

PERL and Spreadsheet::ParseExcel, and Spreadsheet::WriteExcel
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Programming

Perl script to merge cells in column1 which has same strings, for all sheets in a excel workbook

Perl script to merge cells ---------- Post updated at 12:59 AM ---------- Previous update was at 12:54 AM ---------- I am using below code to read files from a dir and print to excel. open(my $in, '<', $file) or die "Could not open file: $!"; my $rowCount = 0; my $colCount = 0;... (11 Replies)
Discussion started by: Jack_Bruce
11 Replies

2. Shell Programming and Scripting

Write two csv files into one excel with multiple sheets

I have requirement to write two CSV files to one single excel with multiple sheets. Data present in the two files should sit in excel as different sheets. How can we achieve this using shell script? 1.csv 2. csv 1,2,3,4 5,6,7,8 XXXXX YYYYY Res.excel 1.csv data... (1 Reply)
Discussion started by: duplicate
1 Replies

3. Shell Programming and Scripting

Perl script to Merge contents of 2 different excel files in a single excel file

All, I have an excel sheet Excel1.xls that has some entries. I have one more excel sheet Excel2.xls that has entries only in those cells which are blank in Excel1.xls These may be in different workbooks. They are totally independent made by 2 different users. I have placed them in a... (1 Reply)
Discussion started by: Anamika08
1 Replies

4. Shell Programming and Scripting

create separate files from one excel file with multiple sheets

Hi, I have one requirement, create separate files (".csv") from one excel file(xlsx) with multiple sheets. These ".csv" files are my source files. So anybody please suggest me the process. Thanks in Advance. Regards, Harris (3 Replies)
Discussion started by: harris
3 Replies

5. Shell Programming and Scripting

Code to get 5 unix files in 5 different tabs in a single excel

Hi All I need to put 5 different files from Unix box in 5 different tabs in a single excel. For this, I need to code only using Unix. Kindly help me on this. ---------- Post updated at 07:23 AM ---------- Previous update was at 06:24 AM ---------- Hi All I need to put 5 different... (2 Replies)
Discussion started by: misssrinivasan
2 Replies

6. Shell Programming and Scripting

Sending SQL Queries output to different Excel sheets

Hi, I need your help in sedning sql queries output to different excel sheets. My requirement is like this: Query1: Select name from table1 where status = 'Complete' Query2: Select name from table1 where status = 'Failed' Query3: Select name from table1 where status = 'Ignored' ... (4 Replies)
Discussion started by: parvathi_rd
4 Replies

7. Shell Programming and Scripting

Add multiple .csv files as sheets to an excel file in unix.

Hi, I am using Solaris 8. My script outputs 4 .csv files. Currently I am SFTPing the files and creating a new excel file with the 4 files as sheets. Can anyone suggest ways to do this in UNIX ? Thanks, David. (2 Replies)
Discussion started by: libin4u2000
2 Replies

8. Shell Programming and Scripting

How to format excel sheets in UNIX??

Hi, I have generated an excel sheet using a shell script. i have converted the output text file to an excel and got the desired output. However, in a particular column in the excel the values of the numbers start with 0. e.g. 078393343, 00342442, etc. But, in the resulting excel I get as... (2 Replies)
Discussion started by: Vijay06
2 Replies

9. Shell Programming and Scripting

Multiple excel work sheets through UNIX

Hi, There is this requirement to create multiple work sheets in an MS Excel file through UNIX. We normally can create one work sheet in unix by either tab or comma delimiting and appending .xls or .csv to the file name, but can we create multiple work sheets. Regards, Puspendu (1 Reply)
Discussion started by: puspendu
1 Replies

10. Programming

creating more than 2 excel sheets in C

Hi, I have a question about using C to write excel file. There is a way to write into a sheet into a file excel, like this: FILE * File; pMyFile = fopen("test.xls", "w+"); fprintf(File, "\n\n"); /* go to the row 2 of the column A*/ fprintf(File, "%s", "Hi pippo!"); /* write... (7 Replies)
Discussion started by: manceryder
7 Replies
Login or Register to Ask a Question