I'm trying to build a pivot report from an array. I have read this pivot doc But I would like a complete example to see it. I have created a datasource as usual, in fact when I show it in a table report it works fine. when I try to create a pivot table
$node = $this->src('sales')
            ->query("SELECT num1, num2, num3, num4
              FROM mydata");
            ->pipe(new Pivot(array(
              "dimensions" => array(
                "column" => "num1, num2"//,
                //"row" => "customerName, productLine"
              ),
              "aggregates"=>array(
                "sum" => "num3,num4"//,
                //"count" => "dollar_sales"
              )
            )))
            ->pipe($this->dataStore('test2'));
I get
Symfony\Component\Debug\Exception\FatalThrowableError thrown with message "Parse error: syntax error, unexpected '->' (T_OBJECT_OPERATOR)"
in this line
->pipe(new Pivot(array(