1 Example
This example shows the total sales of employees Jane, Margaret and Steve. Jane's sales will be compared with the average sales
Parameterization of the box:
- Graph type selector Finviz.
- SQL statement to execute, in this case:
<union type="all"> <select> <columns> invoice.invoiceDate <alias name='date'/>, sum(invoice.total) <alias name='value1'/>, 0 <alias name='value2'/>, 0 <alias name='value3'/>, sum(invoice.total) <alias name='value4'/>, 0 <alias name='value5'/>, 'Jane' <alias name='value1_name'/>, 'Margaret' <alias name='value2_name'/>, 'Steve' <alias name='value3_name' />, 'Jane' <alias name='value4_name'/>, 'Mean' <alias name='value5_name' /> </columns> <from table='invoice'> <join table='customer'> <on>customer.customerid = invoice.customerid</on> </join> </from> <where>customer.supportrepid = 3</where> <group>1</group> </select> <select> <columns> invoice.invoiceDate <alias name='date'/>, 0 <alias name='value1'/>, sum(invoice.total) <alias name='value2'/>, 0 <alias name='value3'/>, 0 <alias name='value4'/>, 0 <alias name='value5'/>, 'Jane' <alias name='value1_name'/>, 'Margaret' <alias name='value2_name'/>, 'Steve' <alias name='value3_name' />, 'Jane' <alias name='value4_name'/>, 'Mean' <alias name='value5_name' /> </columns> <from table='invoice'> <join table='customer'> <on>customer.customerid = invoice.customerid</on> </join> </from> <where>customer.supportrepid = 4</where> <group>1</group> </select> <select> <columns> invoice.invoiceDate <alias name='date'/>, 0 <alias name='value1'/>, 0 <alias name='value2'/>, sum(invoice.total) <alias name='value3'/>, 0 <alias name='value4'/>, 0 <alias name='value5'/>, 'Jane' <alias name='value1_name'/>, 'Margaret' <alias name='value2_name'/>, 'Steve' <alias name='value3_name' />, 'Jane' <alias name='value4_name'/>, 'Mean' <alias name='value5_name' /> </columns> <from table='invoice'> <join table='customer'> <on>customer.customerid = invoice.customerid</on> </join> </from> <where>customer.supportrepid = 5</where> <group>1</group> </select> <select> <columns> invoice.invoiceDate <alias name='date'/>, 0 <alias name='value1'/>, 0 <alias name='value2'/>, 0 <alias name='value3'/>, 0 <alias name='value4'/>, sum(invoice.total)/3 <alias name='value5'/>, 'Jane' <alias name='value1_name'/>, 'Margaret' <alias name='value2_name'/>, 'Steve' <alias name='value3_name' />, 'Jane' <alias name='value4_name'/>, 'Mean' <alias name='value5_name' /> </columns> <from table='invoice'> <join table='customer'> <on>customer.customerid = invoice.customerid</on> </join> </from> <group>1</group> </select> </union>
* The invoice that it has produced is searched for each employee.
INPUTS:
- date: Timestamp with the dates
- value1: Value of series 1 in that Timestamp.
- value2: Value of series 2 in that Timestamp.
- value3: Value of series 3 in that Timestamp.
- value4: Value of series 4 in that Timestamp.
- value5: Value of series 5 in that Timestamp.
- value1_name: Name of the series 1.
- value2_name: Name of the series 2.
- value3_name: Name of the series 3.
- value4_name: Name of the series 4.
- value5_name: Name of the series 5.
Each entry contains the information corresponding to the different series for a specific moment.
The elements of series 4 and 5 are those that are compared and shown in the graph.
2 Interaction
In this type of graph the user can interact to choose how the data are grouped (annual, quarterly, monthly, biweekly, weekly, daily). By moving the mouse across the screen, the exact data is displayed for each point.
- (1) Show the data in the line graph: When placing the mouse on top of the temporary graphs, the value of each data is displayed on the selected date.
- (2) Show the data in the graph: When placing the mouse over a value of the graph, information about that point will be given.
-
(3) Choose temporary group: from the comboBox you can decide if you want to see the data grouped by years, quarters, months, quinzenas, weeks or days. Not all these options will always be available, depending on how the input data is, one or the other will be enabled. Finally, you can always choose the option: "NoFilter", where the data are shown as they have arrived without prior treatment.