KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

Using Cube #437

Open Eric opened this topic on on Aug 29, 2018 - 2 comments

Eric commented on Aug 29, 2018

Hello, I have a question regarding the cube package. I have a simple table that groups all the rows by statuses and display their sum.

Status                Nb of Rows
-----------------------------------
Cancelled            10
Completed            5
Started                 2

I'd like to display the data on one row as follow

Cancelled        Completed            Started
------------------------------------------------------
10                        5                           2

How can I do that using cube?

Thanks

KoolReport commented on Aug 29, 2018

You use the Transpose2 process

use \koolreport\processes\Transpose2;
->pipe(new Transpose2())
Eric commented on Aug 29, 2018

Thank you

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

Cube