Search code examples
excelopentbs

OpenTBS more faster fill xlsx file with over 10000 row


I'm using OpenTBS plugin for TinyButStront template engine more than 4 years, and almost since beginning, I found problem with merging XLSX files with more than 10000 rows in source data array.

Until now, I've used OpenTBS v.1.9.0, and solution which fix this problem, found here : http://www.tinybutstrong.com/forum.php?thr=3256

But, I decided update OpenTBS from v.1.9.0 to latest v.1.9.11, and found that my problem with large data source still not fixed, even that Skrol29 says that in v.1.9.2 "6 times faster when saving XLSX merged sheets with numerous rows."

I've used same fix from http://www.tinybutstrong.com/forum.php?thr=3256 in new v.1.9.11 and it still works and merge numerous rows way faster.

So, Skrol29, can you review again this solution and apply into official release ?


Solution

  • The fix submitted at http://www.tinybutstrong.com/forum.php?thr=3256 has not been implemented as is in OpenTBS because is uses regexp functions. Regexp are smart and powerful, nevertheless they assumes some string disposition that may sometime be different. So they may be not as rigorous as we can expect.

    Thus TBS and OpenTBS simple XML parsing has been thoroughly tested and are more trusted.

    So for this problem of performance with Ms Excel worksheets merging, it is recommended to use the command OPENTBS_RELATIVE_CELLS supported since OpenTBS 1.9.2.