How can I write 1 millions rows data to an excel book ?
every sheet was limited to 65535 rows . if write more than 65535 to a sheet , other will be lost.
Is there any solution?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
So that would be approximately 20 sheets. Should work but we've never tried to create such a big file. Its easy to create a new sheet - just look at the header files.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
You are going to need to spend some of your own time on this - really, you haven't shown that there is any bug, its just that the goal you have of pushing the envelope to the edge of space is not working out of the box.
So try to create three sheets with three cells in each. Then try more cells. Then try 1000 in each of three sheets. Check any return codes that you find. Once you get three sheets working with some relatively small number of cells, try maxing the first and adding 100 cells to the next. At some point you are going to (I suppose) find a problem. Once you have nailed down a simple to reproduce problem then tell us about it.
Yes, I know - this takes time. Well, we who support this library spend huge amounts of time fixing bugs and adding features, and we don't get paid for it.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
How can I write 1 millions rows data to an excel book ?
every sheet was limited to 65535 rows . if write more than 65535 to a sheet , other will be lost.
Is there any solution?
Use the new xml format I imagine. The older format supported by this library has a limit of 64K rows - there is nothing to be done about it.
Use the new xml format I imagine. The older format supported by this library has a limit of 64K rows - there is nothing to be done about it.
One book multi sheets accept. how to do this ?
So that would be approximately 20 sheets. Should work but we've never tried to create such a big file. Its easy to create a new sheet - just look at the header files.
wb = xlsNewWorkbook();
ws = xlsWorkbookSheet(wb, "sheet1");
ww = xlsWorkbookSheet(wb, "sheet2");
for(i=0; i < 65500;i++)
{
for(j =0;j<10;j++ )
{
if(i < 50000)
xlsWorksheetLabel(ws,i,j,"0001234",NULL);
else
xlsWorksheetLabel(ww,(i-50000),j,"4321",NULL);
}
}
strcpy(str,"test.xls");
xlsWorkbookDump(wb, str);
xlsDeleteWorkbook(wb);
while I use this code dump 65500 to file test.xls .
we got 50000 rows in sheet1, no data found in sheet2.
Is there any problem in this code ?
the attachment is the file generated.
platform information
LSB Version: :core-3.0-ia32:core-3.0-noarch:graphics-3.0-ia32:graphics-3.0-noarch
Distributor ID: CentOS
Description: CentOS release 4.4 (Final)
Release: 4.4
Codename: Final
You are going to need to spend some of your own time on this - really, you haven't shown that there is any bug, its just that the goal you have of pushing the envelope to the edge of space is not working out of the box.
So try to create three sheets with three cells in each. Then try more cells. Then try 1000 in each of three sheets. Check any return codes that you find. Once you get three sheets working with some relatively small number of cells, try maxing the first and adding 100 cells to the next. At some point you are going to (I suppose) find a problem. Once you have nailed down a simple to reproduce problem then tell us about it.
Yes, I know - this takes time. Well, we who support this library spend huge amounts of time fixing bugs and adding features, and we don't get paid for it.
well , you people are great! thanks for your selfless dedication.
we tested, it is support maximum 2^15 rows in a sheet.
there was more than 1 millions rows dump to a book , 30000 in each sheet ,we got more then 30 sheets.
50 columns available.
I have got the same problem!