KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.

Server side processing with large json object #1351

Open branden opened this topic on on Mar 18 - 1 comments

branden commented on Mar 18

Hi KoolReport,

I'm trying to use a Json object of +-1 million rows on a datatable. Also, im retrieving the object from an mssql stored procedure which returns the data quite quickly.

Could you offer any advice on how i can achieve this effectively as the only issue im facing is displaying the data?

Im using the datagrid package and im on the latest pro version of koolreport.

here is a snippet of my code:


                'name' => 'network_result',
                'dataSource' => function() {
                    $results = false;
                    $v = DB::connection('sqlsrv')->select("SET NOCOUNT ON; EXEC     Smartz_VVM.MS_SQL.AnalyticsMaster @ID = 92, @C_DATE1 = '2020-01-01 00:00:00' , @C_DATE2 = '2020-01-03 00:00:00'");
                    if (isset($v[0]->Result) and $v[0]->Result != null) {
                        $results = json_decode($v[0]->Result);

                    return $results;

                 //default method = 'get'
David Winterburn commented on Mar 19

Hi Branden,

Does your stored procedure support:

  1. row limit and offset?
  2. filter or where clause?
  3. result count?

Another option is using a restful API which supports the 3 above conditions. Let us know. Thanks!

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
help needed