The wb02 project
General info
Project description
Data source
The About view
The lifeExpectancy view
Changes relative to the wb01 project
Database
General info
This project provides charts of the life expectancy at birth by country.
The user specifies the desired country by entering its name in a text field, as seen below:
Project description
Data source
The project declares an SQL data source consisting of an embedded Derby database stored in a zip file located in the project's directory.
Because Viewreka sets the value of the system property 'user.dir' to the directory of the current project, this property is used in the connection string to locate the database.
The About View
The About view provides an HTML chart with information about this project. The chart content is retrieved from an external file (and it is the document you are currently reading).
The lifeExpectancy View
The lifeExpectancy view provides an XY chart based on the dataset dsLifeExp, which is defined by a parameterized query.
Changes relative to the wb01 project:
- The query of the dsLifeExp dataset is now stored in an external file.
- The string parameter prmCountry is used in the query of the dsLifeExp dataset.
- Labels are attached to the X and Y axes.
Database
This project uses a Derby database compiled from data provided by the World Bank.
The database consists of four tables, as seen in the figure below:
Below is a sample of the data contained in these tables:
The database also contains two views that present the data in a user friendly form, as illustrated by the samples below:
V_COUNTRY
V_INDICATOR