Modify Column Headers in Drillthrough

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Modify Column Headers in Drillthrough

    Hi there!

    I have another interesting question which we happened to stumble upon.
    Is it possible to modify the sql select, sent to the Database storing the Drillthrough Data?

    What we need is the ability to alter the columns names which is pretty basic in SQL.
    I read the "" and studied the OnDrillThrough Event which handles the call.
    What I have learnt is that the sql request itself is written by the server using the $names object in this call:

    Source Code

    1. $response = $server->drillThrough(array('datastore' => $datastore, 'names' => $names, 'values' => $values, 'lengths' => $lengths, 'lines' => $line));

    I was thinking about modifying the elements of $names from "Dimension" to "Dimension as Title" but i doubt that this will work.

    What we need is the final select to look something like: "Select Dimension as Title from tableDrillthrough" instead of Select Dimension from tableDrillthrough

    Maybe someone had the same Taks on hand as I and could point me in the right direction?

    best regards
  • Hi DataPhi,

    I don't think this is possible to alter the SQL Statement cause it's done internally by the ETL Server.

    BUT! you can easily alter the Response of the webservice call (the $return->result variable)

    you can parse it and change whatever you like prior to the rendering to the client

    hope this helps!

    Post hoc, non est propter hoc