By: Budi
Date: 2014-07-02
Time: 06:32
|
add row on runtime odsis it possible to add row to ods file on the fly?
without using multidimensional array. i have a really big dataset, that eats too much memory if placed in an array. so my problem is like this
like this
|
|||
By: Skrol29
Date: 2014-07-03
Time: 03:17
|
Re: add row on runtime odsHi Budi,
If your object $data do inherits from Iterator or ArrayObject, then it can be directly given to MergeBlock() since TBS version 3.5.0.
Otherwise you can create a small database plug-in that will be a reader for your variable $data. See http://www.tinybutstrong.com/manual.php#plugins_db |
|||
By: Budi
Date: 2014-07-03
Time: 06:56
|
Re: add row on runtime odswell, actually my $data is a mysql PDO query and it needs to be process in some way, before i get the correct data for the report.
this is the actual code looks like
|
|||
By: Budi
Date: 2014-07-04
Time: 12:05
|
Re: add row on runtime odsis it possible to make it function like this
search for the tag, insert a copy above tagged row, merge the data, when show is called all block tag is removed. tried reading the code of tbs and open tbs, can't find a clue about how to implement it. haha |
|||
By: Skrol29
Date: 2014-07-04
Time: 12:55
|
Re: add row on runtime odsYour snippet says "$dt = array(...)"
Is this correct or should it be "$dt[$i] = array(...)" ? In the first case you cannot merge row per row because your recordset needs to be entirely read before to display the result. In the second case, you can merge row per row. > is it possible to make it function like this Yes in the second case. This is in the TBS level, not OpenTBS. Use the technical described here: http://www.tinybutstrong.com/manual.php#plugins_db For example:
|
|||
By: Budi
Date: 2014-07-04
Time: 16:55
|
Re: add row on runtime odsah, yes it's indeed
i see, so i can make the calculation in the db fetch thanks for the help Skrol29, will look into it :D |
|||
By: Budi
Date: 2014-07-07
Time: 13:15
|
Re: add row on runtime odshmm, tried using plugins method but still running into memory limit problem.
is it still using array before merging with the xml file? is there anyway to overcome this? before this i was using a simple xls where the output is just echoed with specific header and never run to a memory limit problem. http://www.appservnetwork.com/modules.php?name=News&file=article&sid=8 |