Products

Introducing DataSets

As most of our followers are aware the 1.3 series development preview release has been a long time in the making, in fact we have been working on it for well over a year. As it is getting close to completion and ready for a 1.4 stable release (a big milestone for us!) we thought it would be a good idea to pause and reflect on the new features we have managed to cram in.

The first one we are going to look at is the new DataSets feature.

Overview

DataSets are a new Xibo feature to design and display tabular data, formatted nicely, in a region on a layout.

Examples of where this could be used are:

A drinks menu at a bar

Tee times at a golf club

Meeting room bookings

DataSets have been designed to be versatile and reusable and therefore come in two parts:

The Data (DataSet)

The Display (DataSet View)

This means that you can define a data set as a number of columns, add rows and then create “views” of this data on your layouts.

Creating a DataSet

[![Add DataSet](/content/images/2012/02/add-dataset-300x241.png "Add DataSet")](/content/images/2012/02/add-dataset.png)Form to add a new DataSetDataSets are accessed using the “DataSets” link in the “Management” drop down menu, navigating here will bring you to a very familiar Xibo “table” view of all the data sets you have permission to access. You can add a new dataset by giving it a name and an optional description, you can also edit existing ones and add data.

DataSets also come under the standard permissions options that are available throughout Xibo. The creator of a dataset (or an admin) is able to set the permissions for the DataSet on a user group, or on a user by user basis. Only users with Edit permissions will be able to add/edit data and reorganise the data structure, only users with a view permission will be able to use the DataSet in their layouts.

[![DataSet Columns](/content/images/2012/02/view-dataset-columns-300x220.png "DataSet Columns")](/content/images/2012/02/view-dataset-columns.png)Set the columns you wantThe first thing to do is Add a new DataSet using the Add button (found near the filter form), after doing so the columns of the DataSet can be defined to describe the structure of the data.

Defining the structure of the data

Data Columns are used to define the structure of the data, each column can have a number of settings to achieve this, these are:

Heading (the column heading to appear when you enter data

List Content (enter a comma separated list of values in here to display in the drop down list)

Column Order (the order to place the column)

There isn’t a theoretical limit to the number of columns Xibo can support – although a smaller DataSet is often easier to enter and display than an overly large one. Columns may be extended in the future to have support for different data types – currently only strings are supported.

Note: Columns can be added and removed after data has been entered. The ordering and list content of columns can also be changed after data has been collected.

Once all the required columns have been added, the DataSet is ready to have data recorded against it. This is done using the “View Data” task on the DataSet table view. This view will contain all of the columns that were added in the previous step and allow you to go through each one and enter data. In future we will look to extend this to support an import from CSV file and perhaps a link to 3rd party databases.

There is no “save” button on this interface, Xibo will automatically save your changes after each data entry.

Note: If all the rows are taken, more rows can be added to the data set by clicking the “Add Rows” button.

The DataSet is ready to be used on a layout!

Using the DataSet

[![](/content/images/2012/02/edit-dataset-view-300x267.png "DataSet View Configuration")](/content/images/2012/02/edit-dataset-view.png)Configuring the DataSet View on a LayoutOnce a DataSet has been defined anyone with “View” permissions can use the DataSet on layouts. They are added by selecting the “DataSet” button from a region Timeline, which presents a drop down list of all DataSets available to the user as well as the usual duration field for entering the duration in seconds that the DataSet should be shown.

Once added, the edit dialog will automatically appear allowing the user to pick their options for the DataSet View.

On this form the user can specify:

Duration: The duration in seconds

Update Interval: The duration in minutes the data should be cached on the client

Lower Row Limit: The row number to start displaying the data

Upper Row Limit: The row number to end displaying the data

Order: The Ordering of the data (column name ASC|DESC)

Filter: A filter option to filter the data with (Column Name=Value, Column Name=Value)

Show Table Headings: Whether to show the column headings in the table

Columns Selected: The columns to display (drag or double click to move between lists)

Columns Available: The columns available to select (drag or double click to move between lists)

Stylesheet: A CSS Stylesheet to render with the table

The resulting view will be showing the region preview window and displayed on the client.

Note: Once the DataSet view is configured it will automatically respond to edits made on the data – and it multiple views on the same DataSet can be created.

Summary

We hope this new feature will be useful for anyone wanting to display tabular data and will offer a vast improvement over manually creating a table view in the text editor. We also hope that in the future we can extend this feature to offer some simple chart generation on the client.