Reader small image

You're reading from  Pentaho 5.0 Reporting by Example: Beginner's Guide

Product typeBook
Published inAug 2013
PublisherPackt
ISBN-139781782162247
Edition1st Edition
Tools
Right arrow
Author (1)
Right arrow

Time for action – creating our first sparkline


We will modify our principal data set to practice each of the following points. We will create a subreport, and within it we will create and configure two sparklines.

  1. We modify the SQL query of our data set to conform to the needs of this guide. We add the field customer_id at the end of the list of fields in the SELECT statement. Our query should look like the following:

      SELECT country.country_id, country.country, customer.first_name,customer.last_name, SUM(payment.amount) sum_amount, payment.customer_id
      FROM payment 
      INNER JOIN customer ON customer.customer_id=payment.customer_id
      INNER JOIN address ON address.address_id=customer.address_id
      INNER JOIN city ON city.city_id=address.city_id
      INNER JOIN country ON country.country_id=city.country_id
      WHERE country.country_id IN (20,24,29,34,48,67,74)
      GROUP BY payment.customer_id
      ORDER BY country.country, customer.first_name

    In the Details section, beside the label Trend, we place a...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Pentaho 5.0 Reporting by Example: Beginner's Guide
Published in: Aug 2013Publisher: PacktISBN-13: 9781782162247