Changes

Use iReport

7,246 bytes added, 14:10, 24 October 2012
no edit summary
Data source: Qa
[[Image:Quality Control Summary Report.png|center|500px|''Figure 55.'' ''Sample report- Quality control summary'']]
 
==Appendix A: IMSMA Database==
===Overview===
The IMSMA database contains tables for IMSMA’s base data (country structures, explosive, ordnance, organisations, and places), locations, and the locations’ associated accidents, hazards, hazard reductions, MREs, QCs, and victims.
 
[[Image:fig56iR_Appndx.png|center|500px|''Figure 56. Conceptual database model'']]
<div align="center">
''Figure 56. Conceptual database model''
</div>
 
Within each country structure are zero or more locations. For example, a particular province may have multiple locations within it while another province has no locations. Each location may have zero or more items such as accidents, hazards, hazard reductions, MREs, QCs, or victims associated with them. These accidents, hazards, hazard reductions, MREs, QCs, or victims are added to the IMSMA database via field reports.
 
IMSMA items may have either a direct or a linked relationship to other items. Direct relationships occur when one item requires the other item to exist. For example, an accident, hazard, hazard reduction, MRE, QC, or victim has a direct relationship to the location to which it is associated. The accident, hazard, hazard reduction, MRE, QC, or victim cannot exist unless it is associated with a location. This direct relationship is enforced in IMSMA via the reconciliation process. Direct relationships also exist when subsets of data are contained within an item. For example, an MRE may have MRE details such as the MRE type, total audience, and percentage of women and men. The MRE details data requires the MRE to exist. Table 15. Direct relationships between items lists the items and the data subsets that depend on them.
 
<center>
{| class="wikitable" width="500"
|-
| align="center" colspan="2" | '''Table 15. Direct relationships between items'''
|-
| width="100pt" | '''Parent item'''
| align="center" width="400pt" | '''Child item(s) which require the parent item'''
|-
| Hazard reduction || Impact survey
Interviewee
Organisation
Question
Sample
Sector
Vegetation removal
|-
| Location || Accident
Hazard
Hazard reduction
MRE
QA
Victim
|-
| MRE || MRE details
|-
| Victim || Received MRE
|}
</center>
 
Linked relationships are optional relationships which may exist between items. Accidents, hazards, hazard reductions, MREs, QCs, and victims may be related to one another via links. For example, a victim may be associated to an accident in a particular hazard. If these relationships are known, IMSMA users may define these links while reconciling the field report.
 
===Guids===
All records in IMSMA have a guid. A guid is a unique value that identifies the record in the IMSMA database. Because the guid is lengthy and comprised of alphanumeric characters, it is typically not a useful value to display in a report. However, the guid is necessary in determining which item records have a direct relationship, and in determining what links exists between item records.
 
All accidents, hazards, hazard reductions, MREs, QCs, and victims are associated with a single location. The information about the location to which an item record is associated is stored in the location_guid field of the item table and corresponds to the location_guid of the location to which it is associated ([[:Image:fig57iR_Appndx.png|Figure 57]]).
 
[[Image:fig57iR_Appndx.png|center|500px|''Figure 57. location_guid'']]
<div align="center">
''Figure 57. location_guid''
</div>
 
The location_guid field in the item table contains the guid of the location to which the item record is associated. [[:Image:fig58iR_Appndx.png|Figure 58]] shows an example of a location and the accident and hazard that are associated to the location. Notice that the location_guid value (1234-1234) in the accident and hazard are identical to the location_guid of the location.
 
[[Image:fig58iR_Appndx.png|center|500px|''Figure 58. location_guid example'']]
<div align="center">
''Figure 58. location_guid example''
</div>
 
When you create a report on a location and its associated items, you will need to use location.guid = "$P{'''LocationParamName'''}" in the query of the sub-report where '''LocationParamName''' is the name of the parameter that you created for the location ([[:Image:fig59iR_Appndx.png|Figure 59]]).
 
[[Image:fig59iR_Appndx.png|center|500px|''Figure 59. Sub-report query for location and associated items'']]
<div align="center">
''Figure 59. Sub-report query for location and associated items''
</div>
 
IMSMA allows users to define relationships between item records of differing types. For example, an accident may be related to a particular hazard. These relationships are referred to as links. The link table contains the links that have been defined between item records. The link table contains the guid of the item from which the link was established (from_guid) and the guid to which the link is being established (to_guid). [[:Image:fig60iR_Appndx.png|Figure 60]] shows an example of a link that was created from an accident to a hazard. These links are stored in the link table.
 
[[Image:fig60iR_Appndx.png|center|500px|''Figure 60. Link table example'']]
<div align="center">
''Figure 60. Link table example''
</div>
 
When you create a report that includes linked items, you will need to use links.toGuid = "$P{'''PrimaryParamName'''} in the query of the sub-report where '''PrimaryParamName''' is the name of the parameter that you created for the primary report item ([[:Image:fig61iR_Appndx.png|Figure 61]]).
 
[[Image:fig61iR_Appndx.png|center|500px|''Figure 61. Sub-report query for linked items'']]
<div align="center">
''Figure 61. Sub-report query for linked items''
</div>
 
==Appendix B. Data Source Fields==
The following sections list the various data sources that are available in iReport and the fields within them.
 
Need to add derived fields to this list
 
===Accident===
A field for each country structure level will also be available. Because the country structure levels may vary for each site, these fields are not listed below.
 
<center>
{| class="wikitable" width="500"
|-
| align="center" colspan="2" | '''Accident fields'''
|-
| width="250pt" | '''Field name'''
| align="center" width="250pt" | '''Data type'''
|-
| Accident Description
Accident ID
Area Marked
Area Officer
Clearance In Progress?
Confirmed
Data Gathered By
Date of Accident
Description of ref area
Distance From Nearest Town
Distance From City
Equipment Damage
Guid
Inquiry Report Reference
Lat/Long
Linked Victim Name(s)
Location ID
Mine Action Activity Type
Municipality
Number of Linked Victims
Number of Persons Involved
Property Damage
Reliability of Information
Reliability of Source
Source
Type of Accident
Type of Area
Type of Hazardous Area
Unknown Device
Was Mine/UXO Marked?
|| Text
Varchar(50)
Varchar(38)
Varchar(50)
Varchar(38)
Varchar(38)
Varchar(25)
Datetime
 
Text
 
Float
Varchar(38)
Text
 
A derived field that returns A comma separated list of the names (first and last) of all victims that are linked to the accident.
Varchar(38)
Varchar(38)
Varchar(125)
A derived field that returns the number of victims that are linked to the accident.
Int(10)
Float
Varchar(38)
Varchar(38)
Varchar(50)
Varchar(38)
Varchar(38)
Varchar(38)
Varchar(38)
Varchar(38)
|}
</center>
0
edits