Straight-forward XLS data export in CDA

In previous post we have developed a dashboard with CDE, the dashboard needs a parameterized and secured data access layer to provide the data for the graphs, selectors and texts on the screen while encapsulating the data access complexity - the CDA.

 

Once the dashboard is complete and users find valuable information or spot insightful patterns they would definitely want and ask you to provide data export functionality to the dashboard, which is easier done than said.

 

All you need is a Text Component with this expression:

function() {
  return "<a href='/pentaho/content/cda/doQuery?solution=mySolution&path=%2FmyFolder&file=myDashboard.cda&dataAccessId=myQueryName&outputType=xls&parammyParam="+myParam+"&parammySecondParam="+mySecondParam+"' target='_blank' title='Export to xls'><img src='/pentaho/public/export.png'/>Export</a>";
} 

 

This will create a link (image+text) which when clicked would open a new tab or window and would start a dowload for the data in xls format.

 

You need to replace my variables with your cda name and path, and to pass the required parameters as paramXXX=YYY.

 

CDA Documentation is available here

Thank you for your interest!

We will contact you as soon as possible.

Send us a message

Oops, something went wrong
Please try again or contact us by email at info@tikalk.com