Creating a Dashboard Table component

In this recipe, we are going to add a Table component to a dashboard so that we can render a data source result for the user.

Getting ready

To get ready for this recipe, you first need to start the MongoDB server with the same database as that of the last chapter. You will also need to start the Pentaho BA Server using the server control scripts. Once it is started, you should be able to log in to the BI Server.

How to do it…

Proceed with the following steps:

  1. In the PUC, go to File | New | CDE Dashboard.
  2. Save your dashboard in Public | Pentaho MongoDB Cookbook | Dashboards with the name Table Component.
  3. Click on Settings in the CDE Main Menu.
  4. Click on the Layout tab.
  5. Then click on the Add Row button.
  6. Select Row.
  7. Set the Name property to ROW1.
  8. Then set the Height property to 300, as shown here:
    How to do it…
  9. Click on the Data Sources tab.
  10. Expand the KETTLE Queries data source category.
  11. Click on the kettle over kettleTransFromFile data source.
  12. Set the Name property to QUERY1.
  13. Click on the Browse button on the Kettle Transformation File property.
  14. Navigate to Public | Pentaho MongoDB Cookbook | Transformations.
  15. Select Chapter7-getorders.ktr.
  16. Click on OK.
  17. Set the Kettle Step name property to OUT, like this:
    How to do it…
  18. Click on the Component tab.
  19. Expand the Others category.
  20. Add a Table Component.
  21. Set the Name property to TABLE1.
  22. Then set the Datasource property to QUERY1.
  23. Next, set the HTML Object property to ROW1, as follows:
    How to do it…
  24. Click on Save.

We can now preview our dashboard as follows:

How to do it…
  1. Click on the Opened menu on the Pentaho User Console and select Browse Files.
  2. Navigate to Public | Pentaho MongoDB Cookbook | Dashboards.
  3. Select the Table Component dashboard file.
  4. Click on Opened on the right-hand side menu and the following screenshot should appear:
    How to do it…

How it works…

In this recipe, we created a simple but functional dashboard. After we had created an empty dashboard, we created a data source based on a Pentaho Transformation. Finally, we added a Table component to the dashboard, hooked it up with the QUERY1 data source, and placed it on a layout row called ROW1.

These are the basics you need for 99% of your dashboards. You need a layout, data sources, and components that execute the data sources and render the results on the dashboard layout.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset